Transfering size between partitions

Below is a list of the file system on my Sun system. How can I transfer more disk space from the "/space" partition to the "/" partition with out rebuilding?

/ /dev/dsk/c0t0d0 6191949 5736718 393312 94%
/proc /proc 0 0 0 0%
/dev/fd fd 0 0 0 0%
/etc/mntta mnttab 0 0 0%
/var/run swap 69922 2 69920 1%
/tmp swap 69922 3 69920 1%
/space /dev/dsk/c0t0d0 12529779 232078 12172404 2%
/home/faculty /export/home/fa 6191949 5736718 393312 94%

Hi,

What do you use for kind of a diskmanager?

Veritas Volume manager ?
SDS/ODS
Or just plain FS ?

df -kl, will let me know what you use.

It's most of all easy to grow an FS, shrinking however is a little harder. Also Online JFS would be something nice to have.
Waiting for your reply.

Regs David

When this box was built, someone took Sun's default layout. This puts /var, /usr, and /opt all in root. I think that all 3 are a mistake, but /var is especially bad. Anyone can create files in /var/tmp.

Make sure that you don't have a lot of junk in /var. Have you cleaned it up?

Im not really sure what disk manager im using. Here is the output of the df -kl command:

$ df -kl
Filesystem kbytes used avail capacity Mounted on
/dev/dsk/c0t0d0s0 6191949 5736719 393311 94% /
/proc 0 0 0 0% /proc
fd 0 0 0 0% /dev/fd
mnttab 0 0 0 0% /etc/mnttab
swap 559416 16 559400 1% /var/run
swap 559424 24 559400 1% /tmp
/dev/dsk/c0t0d0s3 12529779 232078 12172404 2% /space
/export/home/faculty 6191949 5736719 393311 94% /home/faculty

thanks

Hi,

This shows you that you have no volume manager at all.

It's going to be quiet hard to change this. It can only be done using "format" and increase/decrease the specified slice.

I strongly recommend to not do this. It will not be safe to do. As Perderabo already told. It's not the best install. Please see if you can re-install or else add an extra root-disk.

also Veritas Volume manager should be free of use for the rootdg (rootdisks).

Regs David

First off what is the best way to check the size of a directory and its content? Secondly what can be cleaned out of /var?

Also, what is the best way to configure the File System when installing a new OS?

du -ks /var/* | sort -n | more

Should show you each file and directory in /var sorted on size.
It's not defenit what can be thrown away.

find / -name core -type f

Shows you core files that can be thrown away.

find / -type f -size +10000000c -exec ls -l {} \;

should show you files larger than 10Mb. It might be nice to take a close look at these.

fuser -fu <file>

Would be nice to examine before removing a file. In case of a doubt only null a file like :

>/my/path/to/file

Please try to get a course, you seem to miss quiet some basics.

Regs David

based on your df output you could link directories to /space like /usr /opt. i would recommend to do this in single user mode or even better with a live-cd-os. be carefull: you have to keep the permissions otherwise your system will never come up. i would work with find and cpio.....

eg.:
root@/opt # find . -print -depth | cpio -pdmu /space/opt/

greetings Pre�y

I finally got a chance to use your suggestion Pressy. It worked great. I used it on another machine that had no room left in /var so I used your solution to transfer /var/sadm to /. I do have a question though. what if i want to do that with /var. when you try and delete /var it will not allow it so then you cannot create the symbolic link.

Thanks

hmm......
never tried it with /var, could be difficult, because /var/run ....
but you could clean up your /var
e.g.
/var/crash
/var/adm
/var/sadm

but if you have a free partition or a new disk you could copy it while using a live-cd-OS.

greetings Pre�y