Can't delete file in linux/centos? or Operation not permitted

if you are unable to delete the file from the root in centos or any Linux then follow this tutorial.

 

  1. Run yum remove e2fsprogs
  2. yum install e2fsprogs
  3. chattr -ia /file/name/example/test.php
  4. rm -rf /file/name/example/test.pp

 

Done, 100% this will help you to delete any file that shows Operation not permitted 

 

the first command will remove chattr from your Linux in case corrupt anyfile of chattr or if you see any error like chattr not found or chroot not found, removing the chattr from server will help you to install it again with valid files 

 

then yum install or apt-get install will help you to install chattr /chroot in your server without any issue

 

chattr -ia this command remove any permission limitation on your file and set remove chattr lock and you can easily remove the file 

 

rm -rf will help you to delete the file!

 

 

Tutorial By Shahid Malla

Thank You

 

  • Operation not permitted, Can't delete file in linux, chattr, chroot, share license delete
  • 19 Users Found This Useful
Was this answer helpful?

Related Articles

DOS and Linux Commands

Table C-1. Similar Commands Command's Purpose MS-DOS Linux Basic Linux Example...

Anonymous Port Scanning: Nmap + Tor + ProxyChains

Install Tor + Nmap + ProxyChains To perform an anonymous port scanning, we need to install the...

When does LVE manager Loading and not working?

Permission problems Similarly, wrong permissions also create problems. For instance, in one of...

rebuildhttpdconf Apache in cpanel

# cd /etc/ # mv apache2 apache2bk # yum reinstall ea-apache* -y # /scripts/rebuildhttpdconf #...