Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have SuSE 8.0 installed. When I installed this OS there were two identical hard drives. KDiskFree reports /dev/hdi2 as / and /dev/hdk2 as 'data1'
so this tells me hdi2 is my system and hdk2 is data1 (not sure what this means exactly)
when I use Konquerer to navigate around root, I see data1 in the directory tree and when I go into it it has the same root directory structure. I didn't think much of it since I had two 40 gig drives- so I just ignored it.
Well, I'm steadily running out of space and would like to use the second drive. I have noticed that none of the programs I've installed to /home/user show up in data1. So the question is- can I just delete everything in data1 and use it as a storage drive?
Also-
any recommendations for a backup utility? What directories need to be backed up? I used to like using ghost when I was windowing. I know I can use it still but I'm not sure which directories to backup besides /home and /usr?
I used to keep all the system files on one partition, programs on another and a storage partition. I could back up my c:\ to a CDR and just re-image whenever something went wrong. What should I do in the linux world?
It sounds like you are saying it's your / folder, you cannot just delete what's there
look at this
[root@Micro Office]# mount
/dev/hda7 on / type ext3 (rw,noatime)
none on /proc type proc (rw)
devfs on /dev type devfs (rw)
none on /dev/pts type devpts (rw,mode=0620)
none on /dev/shm type tmpfs (rw)
/dev/hda5 on /mnt/windows type ntfs (rw,iocharset=iso8859-1)
/dev/hda1 on /mnt/windows_c type ntfs (rw,iocharset=iso8859-1)
/proc/bus/usb on /proc/bus/usb type usbdevfs (rw,devmode=0664,devgid=43)
see where it says /dev/hda7 is mounted on /
in the first line
this means that / (called the root folder) is on the partition that's /dev/hda7
you need to look at that and see where the partition you want to use is mounted.
It sounds like you have several partitions mounted, probably
/
/usr
/var
/home
you need to decide how you want it split up on the free drive, then you can partition the free drive the way you want, format it, mount it on your system and copy everything over to the proper folders on it.
then you would change /etc/fstab
make any changes needed in the /etc/lilo.conf file and run lilo
I would make sure I had a working boot disk first
then just setup the empty drive for the system the way you want it
then copy files over to it, you don't need to copy /proc/ just have it an empty folder
this is probably not something for a beginner to try
However if you post your fstab file and the output of mount then maybe you could just move a partition or two somewhere without moving everything
also post the output of df
[root@Micro root]# df
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/hda7 7684844 4275728 3018740 59% /
none 127724 0 127724 0% /dev/shm
/dev/hda5 3076412 1993064 1083348 65% /mnt/windows_d
/dev/hda1 8393928 7385172 1008756 88% /mnt/windows_c
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/hdi2 18961408 17336328 1625080 92% /
shmfs 514560 0 514560 0% /dev/shm
172.16.1.104:/home 8723020 2577720 6145300 30% /mnt/stevie-linux
_____
mount:
/dev/hdi2 on / type reiserfs (rw)
proc on /proc type proc (rw)
devpts on /dev/pts type devpts (rw,mode=0620,gid=5)
shmfs on /dev/shm type shm (rw)
usbdevfs on /proc/bus/usb type usbdevfs (rw)
172.16.1.104:/home on /mnt/stevie-linux type nfs (rw,addr=172.16.1.104)
_______
So I guess I should have mentioned that I have been using Kdiskfree to mount the 'data1' drive. It does not mount automagically.
the folder data1 appears in my root directory but it shows no contents until I mount the drive. Then it looks like the / directory structure at the time I installed. There are no extra users (I'm using samba) in home, and none of the programs I've installed show up. Here's mount after I mount the hdk2 (data1) :
/dev/hdi2 on / type reiserfs (rw)
proc on /proc type proc (rw)
devpts on /dev/pts type devpts (rw,mode=0620,gid=5)
shmfs on /dev/shm type shm (rw)
usbdevfs on /proc/bus/usb type usbdevfs (rw)
172.16.1.104:/home on /mnt/stevie-linux type nfs (rw,addr=172.16.1.104)
/dev/hdk2 on /data1 type reiserfs (rw,noexec,nosuid,nodev,user=dfinger)
It now shows up... in the last line. df gives this now:
well your problem seems to me that / is running low
it also looks like all the system folders are in root except /home
you can get a lot of space back in / by making a partition in some free space on an unused drive, formating it, and moving the files over to it. then mount it in a folder under /
If you have a fairly large drive that you want to use I would move /usr over to it like this
I will pretend it's /dev/hdb but it could be anything
make partition we will call hdb1
format it
mke2fs /dev/hdb1
tune2fs -j /dev/hdb1
or use whatever fs you want
mkdir /tempdir
mount /dev/hdb1 /tempdir
mkdir /tempdir/usr
cp -a /usr/* /tempdir/usr
now you need to make sure everything is there before removing it from /usr
umount /dev/hdb1
rm -rf /usr/*
mount /dev/hdb1 /usr/
you should have everything in /usr and everything is good to go
for boot up
add the line to mount /dev/hdb1 on boot in fstab
/dev/hdb1 /usr ext3 defaults 1 1
when you delete all files from /usr it will give the space to /
when you mount /dev/hdb1 in /usr it will have it's free space in /usr and will not use any space in /
all you need to do is have the empty folder /usr in / and mount /dev/hdb1 on it.
Last edited by DavidPhillips; 09-22-2002 at 04:10 PM.
I don't know what that is, it sounds like a backup of somekind or another system that you can boot if you set a different root
I do know that mounting a unix file system tree in /data1 probably serves no purpose other than to be able to acces it. But I'm not sure what you have there.
You could try this and see what it is
chroot /data1
now you are in the other system using it's files and / is actually /data1
pt.1
Hey thats some really helpful stuff. Thanks alot for the instructions. It's really nice and sunny out right now though and the dog has his leash in his mouth. so I'll need to give it a try tomorrow. just had a brainstorm -- maybe just unplug the drive... eh. the simple answers are faves. I'll post results
pt.2
as for chroot-
dfinger@stevie1:~> chroot /data1
chroot: cannot change root directory to /data1: Operation not permitted
then I tried it as su-
stevie1:/home/dfinger # chroot /data1
chroot: cannot execute /bin/bash: No such file or directory
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.