LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   root 100% use (https://www.linuxquestions.org/questions/linux-newbie-8/root-100-use-301063/)

amer_58 03-13-2005 07:02 AM

root 100% use
 
My root folder is full..

Was it wrong just to have 1GB for root... However; What options do I have now, Can I max the size of root by taking space of other partitions....

Code:


root@Admin:~# df /home
Filesystem          1K-blocks      Used Available Use% Mounted on
/dev/hda8            26158884    32832  24775792  1% /home

Filesystem          1K-blocks      Used Available Use% Mounted on
/dev/hda2              972564    972564        0 100% /

root@Admin:~# df /opt
Filesystem          1K-blocks      Used Available Use% Mounted on
/dev/hda7              2847720    578620  2122108  22% /opt

root@Admin:~# df /usr
Filesystem          1K-blocks      Used Available Use% Mounted on
/dev/hda6              8045404  2481504  5148624  33% /usr


Tuttle 03-13-2005 07:19 AM

You have probably filled up /var and /tmp, boot with a rescue disk and clear these folders out.
It is a good idea to have separate partitions for /tmp and /var then make root as small as possible.

chbin 03-13-2005 07:28 AM

hmm, what are you storing in the / folder. tells me you are most likely using the root account for things other than system maintence, which is not a good thing to be doing.

amer_58 03-13-2005 07:30 AM



Next post

amer_58 03-13-2005 07:36 AM

Quote:

Originally posted by chbin
hmm, what are you storing in the / folder. tells me you are most likely using the root account for things other than system maintence, which is not a good thing to be doing.
you are right, sth that I dont understand i though I was suppose to save all my files on my home directory and the icon which is placed on my desktop "Home" if i open it it will open the root directory...so basically I have saved all my files on the root dir...


Am I missing anything....

acid_kewpie 03-13-2005 08:15 AM

so /root = "home"? in that case you're running X as root, which is really stupid idea. you should be runnign X as a normal user, then all your files would go to /home/username/

BUT again you seem a bit confused about the whole partition thing... what says what is actually full? please run "df -h" in a console and show us the EXACT output, so we can see for ourselves what the situation is.

Komakino 03-13-2005 08:18 AM

Are you logging in as root rather than a normal user? That's the impression I get from what you say about clicking your home icon... if that's the case then DON'T! Create yourself a proper user (adduser <name>) will do it and don't sign in as root unless you really really need to do some sort of specific system task.

Oh, and fire up knoppix and use qtparted to resize your partitions a little.

chbin 03-13-2005 08:19 AM

well make an account with

$ adduser

and use it for day to day stuff. then it would be impossible for that user to create any files on the / directory as he doensn't have permission.

running around you machine as root is dangerous. far to much power to break things. Also, running things like firefox and downloading files as root is a security nightmare. In fact there is never any reason to log into X as root in the first place. root should only be used for system maintenence, upgrading packages, compiling and installing code, editing /etc files, etc.

chbin 03-13-2005 08:39 AM

after you created a new user. log in as root :). going into the /root directory and mv anything you want to keep into /home/createduser dir. chmod createuser.users *.

then if you like. just to make things clean. go back into /root and do a rm -r * and rm -r .* to get rid of all the X,kde,gnome and whatever config files that shouldn't be there in the first place. I like the root directory being clean.

then just in case, go into /tmp as root and do an rm -r * and rm -r .*. reboot. you are now clean. log into created_user and then X and then firefox or whatever you like.

your /var directory shouldn't be a problem because crond uses logrotate to keep it stable, unless of course you are running a mail server or something, but for some reason I seriously doubt that ;)

amer_58 03-13-2005 08:41 AM

Thanks guys, as far as for df -h this is what I get:

Filesystem Size Used Avail Use% Mounted on
/dev/hda2 950M 483M 419M 54% /
/dev/hda6 7.7G 2.4G 5.0G 33% /usr
/dev/hda7 2.8G 566M 2.1G 22% /opt
/dev/hda8 25G 208M 24G 1% /home
/dev/hda1 37G 10G 27G 28% /windows

I have copied my personal folders from /root into /home....

amer_58 03-13-2005 08:46 AM

In my I have these files in m /tmp:

gconfd-root/ kde-root/ ksocket-root/ mcop-root/ orbit-root/ scrollkeeper-root/ tmp.xpi

is it ok to delete them?

chbin 03-13-2005 08:51 AM

you could delete everything in /tmp. it only becomes a problem if you are on multi-user system with someone else logged on at the same time you are deleting everything in /tmp directory, because will you are deleting it they may be changing it. since you are only logged in as root and no one else is logged into your machine go ahead and do a

$ rm -r *
and
rm -r .*

then reboot. YES IT IS PERFECTLY SAFE. DON'T WORRY NOTHING WILL BREAK.

chbin 03-13-2005 08:59 AM

also go back into you /home/created_user directory as root and do a

$ chown -R createuser.users *

this will make all those files you moved into it from root accessable my you genernal user.

then log out and log back into you created user and don't use root anymore except for the things we have said.

chbin 03-13-2005 09:00 AM

$ chown -R createuser.users *

where createuser = name_of_user_you_created

chbin 03-13-2005 09:26 AM

You have probably filled up /var and /tmp, boot with a rescue disk and clear these folders out.
It is a good idea to have separate partitions for /tmp and /var then make root as small as possible


deleting the /tmp directory in single user mode can be done with a rescue disk.

also deleting everything /var will break stuff unless you recreate the directory structure and touch certain files that need to be there. For instance, if you delete a file that is being used by syslog then even after reboot syslog wont recreate it, unless you do a touch file first.


All times are GMT -5. The time now is 09:19 AM.