Jump to content

Logging in as root graphically? [solved]


FlyingPenguins
 Share

Recommended Posts

Occasionally, in Mandriva 2008 I need to log in as root graphically from my current account that has lower permissions. Sometimes I need to do tasks that I can't do on my normal account, such as removing entries from the GRUB config file if Mandriva decides to add extra entries onto it for some reason, or placing/removing files from protected directories.

 

Yes, I understand the risks with doing things under root, but some things I find would be much easier doing graphically rather than in a console with su.

Link to comment
Share on other sites

There is a menu option, and forgive me because I've forgotten where it is but I know it's inside one of those 'more applications' links, that will allow you to open a file browser as root which will allow you to edit those files through a gui editor if you choose.

 

Another option, and I know you said you didn't like the command line, would be to open a terminal (or the run command option) and type:

 

su -c 'kwrite /path/to/file'

 

with the quotes and that will open up that file, in kwrite, as root after prompting you for the root password.

Edited by liquidzoo
Link to comment
Share on other sites

You don't need to login as root. Just use gksu in Gnome or kdesu in KDE to get the root privileges as and when you need it. For example, to edit grub config.

 

Press ALT-F2
gksu gedit /boot/grub/menu.lst

 

supply root password, then do what you want with the file. Or, for KDE:

 

Press ALT-F2
kdesu kwrite /boot/grub/menu.lst

 

will solve all your problems. The gksu/kdesu is the same as the console su command but graphically being ran. Then you just give it the command you want to run, for example gedit/kwrite to open a notepad equivalent for editing files, and then the last part the actual file to edit.

 

Alternatively, forget the filename, and then just open it later once gedit/kwrite is running.

 

EDIT:

 

greg2 beat me to it lol.

Link to comment
Share on other sites

kdesu is a KDE command, whereas gksu is a gnome command. If you don't have Gnome installed and running, then it won't work for you. Therefore, kdesu is to be used with KDE, and then whatever application that follows it, kwrite, kate, konqueror, firefox, etc, etc.

Link to comment
Share on other sites

If you're using the KDE desktop, you would need to install gksu, but you really don't need it.

 

You can use kdesu on most kde apps, to run them as root, but be careful. It's better for you now, until you become more familiar with Linux to use the openasroot tool (IMO).

 

 

Edit: Ian beat me to it that time.

Link to comment
Share on other sites

My approach is almost as easy as the above mentioned ones. First I install nano. Way easier to use and more intuitive editor than vi imho. Then I open a terminal window, log in as root on the command line and launch

 

nano /boot/grub/menu.lst

 

then edit the entries, save and exit. That's it. It is not more complicated than logging into a gui as root and it is more secure. Just give nano a try, I do believe that you will like it. :thumbs:

Link to comment
Share on other sites

linux needs an elevate rights button popping up in case an application needs more rights to do what you tell it to, maybe using policykit....

 

my new laptop uses face recognition to login, actually it's an addon made by asus, together with policykit it could make administritive rights very secure and yet unobtrusive (confirm identity and click yes to confirm administrative request)....

Edited by ffi
Link to comment
Share on other sites

Linux does do this for some applications. If you try to change the clock time/date, for example, it will ask you for root password. It doesn't do it for all apps, since some can be run as normal user as well as root user just some functionality is disabled if you run it standard.

Link to comment
Share on other sites

  • 3 weeks later...
linux needs an elevate rights button popping up in case an application needs more rights to do what you tell it to, maybe using policykit....
Talk to the developers of the application in question. The ability is there, but it's up to the developers of the application to implement it.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...