LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Run as (https://www.linuxquestions.org/questions/linux-newbie-8/run-as-771754/)

fedix 11-26-2009 12:59 PM

Run as
 
Is there a way to run a GUI file manager as su or root? Alternativel, how do I del a whole directory and all its files and sub directories?

I'm using Fedora 11

Regards

catkin 11-26-2009 01:30 PM

Open up a command prompt as root, cd to the directory above the directory you want to remove and rm -fr <name of directory you want to remove>.

Take care, though; making a mistake when running rm -fr as root has got many of us in trouble!

bigrigdriver 11-26-2009 01:37 PM

If the directory and files you want to delete are in your home directory, use 'rm -rf /path/to/directory' to delete them (in a terminal). If you su to root, use the same command to delete an unwanted directory anywhere in the filesystem.

NOTE: Using su to delete directories outside your home directory is is very risky. Any mis-typed command could make the system unbootable.

If you are using the KDE environment, 'kdesu konqueror' will open konqueror with root privileges. Be very careful deleting directories this way. Be sure you have a recent backup ready to restore. Any typo could cause you a lot of grief.

jefro 11-26-2009 04:21 PM

su mc
sudo mc

lazlow 11-26-2009 05:49 PM

Assuming Gnome: Open a terminal, su -(su space dash), type nautilus and hit enter. You are now running as root with all it's powers(be careful).

Quote:

[fred@localhost ~]$ su -
Password:
[root@localhost ~]# nautilus
Initializing nautilus-open-terminal extension


catkin 11-27-2009 12:52 AM

Quote:

Originally Posted by bigrigdriver (Post 3770565)
Any typo could cause you a lot of grief.

True, but let us not exaggerate the danger; many of us do it regularly without problem. It has been said that it is more dangerous to run a GUI with root privileges (but I have not seen the reasons explained).

brianL 11-27-2009 03:26 AM

I thought it was:
for Gnome: gksu or gksudo whatever.
for KDE: kdesu or kdesudo whatever.


All times are GMT -5. The time now is 03:02 PM.