Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Our AIX 5.3 IntelliStation was running out of space in the /home directory and we needed to move the /home directory to a different location.

Fortunately, the IntelliStation we are using had a second harddrive "hdisk1" which was not used at all.

Please note: I am working as a software engineer, not as an admin. But since we don't have a dedicated AIX admin, I am feeling somehow responsible for this machine.

I am very confused with all this AIX specific stuff:

  • Volume Groups
  • Physical Volumes
  • Logical Volumes
  • Journaled Filesystems and Filesystem Logs

... and I need some help.

share|improve this question
    
You should post this as a question with a separate answer. You can answer your own questions. –  Dennis Williamson Nov 25 '09 at 20:12
    
ok, thanks a lot. I will do so. –  Vokuhila-Oliba Nov 25 '09 at 20:16

1 Answer 1

up vote 1 down vote accepted

Meanwhile I found a solution for the topic mentioned. But I would like to let others know how I did that.

I found this great description from a guy whose name is "Ryan".

see: Ryan's AIX description

The only thing I had to change was: use jfs instead of jfs2 (for whatever reason).

Here is a summary of the commands I used to get this working:

1. mkvg -y homevg hdisk1                    # create a new volume group on the new/free  harddisk
2. mklv -t jfslog -y loghomevg homevg 1     # prepare log for the new filesystem
3. mklv -t jfs    -y    homelv homevg 64G   # prepare a 64G partition for the new /home
4. mkfs -o log=/dev/loghomevg  -V jfs /dev/homelv # create new jfs filesystem.
5. mkdir /home2                             # create a mountpoint for the new filesystem
6. chown bin:bin /home2                     # set ownership according to /home
7. mount -o log=/dev/loghomevg  /dev/homelv /home2 # mount the new filesystem

Note: in (4) you have to answer with "Yes". Afterwards it will take a while to complete.

After all that I copied the original content of the /home directory to /home2. I did so by using gnu tar, but other approaches should also work:

cd /home
gtar -cvpf - * | gtar -C /home2 -xpf -

you are done now!

finally you could unmount /home and use /home2 as the new /home directory, e.g. by modifying /etc/filesystems appropriately. Alternatively you could assign a new home directory to the users defined in /etc/passwd, e.g. use /home2/buildsys instead of /home/buildsys

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.