LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   switching to root (https://www.linuxquestions.org/questions/linux-newbie-8/switching-to-root-135463/)

Stan the caddy 01-16-2004 12:18 PM

switching to root
 
Hi. Can someone please tell me how to switch to root temperarily in KDE (without having to log out, log in as root, do whatever, then log back in as user every time a small change needs to be made)?
Thanks

MasterC 01-16-2004 12:22 PM

Depends on the application. If you mean to simply swith in the command line, you type:
su -

And enter the root password. If you wish to launch gui applications with root's power, that's a bit more involved, but not much. You, as the user, have to execute a command to allow others to use your X window:
xhost+
And then su as root as described above, and type the name of the application to launch. However, it should be noted that you should rarely need to use root, especially in a graphical env.

Cool

Stan the caddy 01-16-2004 04:14 PM

So there isn't an application in kde that allows you to put in your root password without going to the command line? What if I wanted to download to a directory that I don't have write premission to? Just switching user in the terminal woulden't wont allow me to write to the directory outside terminal. Would I really have to give myself premmision to the directory, download, then switch the premission back? I have to say, all this user switching and file premisions is one of the things I find very irritating about Linux.

XavierP 01-16-2004 04:22 PM

Why would you want to download to a directory you don't have permission to? You would just end up with odd files throughout your system which would mess up your system. Far better to d/l to your /home and then do the install.

TheOneKEA 01-16-2004 04:45 PM

What XavierP said. The file permissions that prevent you from messing with files willy-nilly is one of the major strengths of the Linux security model, and acts as the foundation of the strong Linux security that we all know and love.

If you really want to run GUI apps as root, try the "kdesu" command.

Stan the caddy 01-16-2004 05:19 PM

Odd files throughout my system? It seems to me that all linux is is a huge collection of odd files. I mean, when you install a program files from it get thrown everywhere with no with no prompt for an destination directory, and when the program isnt in an rpm you can't (to my limited knowledge) even uninstall it, so this mess of files just keeps piling up. And as for the security thing, if you want to look at a file on your system how is having to type su password going to detur you? Its not like only certian files are protected, everything but your home dir is, so it not as if you'll attempt to open a file , see premission denied and say to your self "Premission Denied! I dont see that everywhere in linux, I think i'll steer clear!" The whole thing just seems like a giant pain in the ass to me.

XavierP 01-16-2004 05:30 PM

Those 'odd files' are all there for a reason - check out Rute for more detail.

Non-rpm files can be uninstalled, by issuing a "make uninstall".

The security thing is there for a very good reason. One of the problems with Windows is that every file is available to every user. Your box is open to people deleting things and moving them and installing spyware and viruses, either maliciously or carelessly. In Linux you can only do that if you have root permission. If you don't have the root password (and remember that Linux has been a network OS from day 1) the if you get "permission denied" you will steer clear.

Stan the caddy 01-16-2004 05:45 PM

Fine. I can understand if your running a network you would need to have a root account, file premissions, and all that but on a home computer it just gets in the way.
As for the "make uninstall" thing, that only works if the developer of the program wrote such a program, which they usually do not.
And heres anouther comparison between windows and linux. I just got a new video card recntaly, it took me all of 3 minuites to install the driver and get it running on windows. Its been 3 days now and i'm still trying to get the linux driver working. In fact you hardly ever have any problems installing/uninstalling software on windows, linux on the other hand...
Thanks for that Rute thing though, I do belive i'll read through it. Despite my feelings so far about linux, I still want to learn.

XavierP 01-16-2004 05:58 PM

Valid points. With the 'make uninstall' command, I agree, you are dependent on the programmer making the install uninstallable. There is a program called checkinstall, I nderstand that this will enable uninstalls.

The root/file/etc permissions are valid whether you run a stand alone or a network box. Physical security is as important as having stacks of security programs running. A couple of members of this board discovered this as their friends/family changed things on their box when they weren't around. It also keeps you from making mistakes - it is easy enough to delete an essential file and you won't notice it until you next reboot and then wonder why your system won't start.

I agree about the video card drivers. I think ( and this is IMO) that Nvidia have the best installer. Once I actually read the instructions, it took 3 minutes to install the driver. Remember also, video drivers tend to be closed source/proprietary so we are at the mercy of the driver manufacturer. Then again, I remember the fun I had when I installed W2K with an Nvidia card - up came the system, I opened IE to download the latest driver and lo, the message opened up that I needed more than 640x480 (the generic no driver setting) to be able to get the driver. Not a happy bunny. At least Linux comes with text based browsers, so even if you can't boot into X at all, you can still hit the web to fix your problems.

Seriously, do stick with it. A lot of it is trial and error and lots of cursing ;) but LQ is full of help and helpful people, there are thousands of programs available for free and you won't miss the BSOD at all ('cos there's a BSOD screensaver :D). If a Win program crashes, it takes down the whole system, if a Linux program crashes, only the program is killed, the system is fine.

MasterC 01-17-2004 02:54 AM

Quote:

Originally posted by Stan the caddy
Fine. I can understand if your running a network you would need to have a root account, file premissions, and all that but on a home computer it just gets in the way.
As for the "make uninstall" thing, that only works if the developer of the program wrote such a program, which they usually do not.
And heres anouther comparison between windows and linux. I just got a new video card recntaly, it took me all of 3 minuites to install the driver and get it running on windows. Its been 3 days now and i'm still trying to get the linux driver working. In fact you hardly ever have any problems installing/uninstalling software on windows, linux on the other hand...
Thanks for that Rute thing though, I do belive i'll read through it. Despite my feelings so far about linux, I still want to learn.

Please keep your thread on topic. If you have a complaint about Linux versus windows, there are plenty of threads available to do so ;) If you have a desire for a more in depth reason behind your question's answer, feel free to press on; but please try to do so without the "finger pointing" notions.

Thank You.


All times are GMT -5. The time now is 10:29 PM.