Tanti Technology

My photo
Bangalore, karnataka, India
Multi-platform UNIX systems consultant and administrator in mutualized and virtualized environments I have 4.5+ years experience in AIX system Administration field. This site will be helpful for system administrator in their day to day activities.Your comments on posts are welcome.This blog is all about IBM AIX Unix flavour. This blog will be used by System admins who will be using AIX in their work life. It can also be used for those newbies who want to get certifications in AIX Administration. This blog will be updated frequently to help the system admins and other new learners. DISCLAIMER: Please note that blog owner takes no responsibility of any kind for any type of data loss or damage by trying any of the command/method mentioned in this blog. You may use the commands/method/scripts on your own responsibility. If you find something useful, a comment would be appreciated to let other viewers also know that the solution/method work(ed) for you.

Sunday 26 June 2011

AIX - LVM - Change File System

AIX - LVM - Change File System

Using chfs command we can rename and increase the size of the file system online

We want to increase file system size

#chfs –a size=+block size /filesystem name
#chfs –a size=+32m /filesystem name
#chfs-a size=+4g /filesystem name

+block size – We can mention the size using blocks (2048 blocks = 1MB)
+32m – We can mention the size using MB
+4g – We can mention the size using GB


After increasing the file system size, we can verify using commands

#df –k
#ls –q /newfs

Rename the file system using chfs command

#lsfs /newfs
It will display /newfs details
#

Now we want to rename /newfs to /testfs then your command will be

#chfs –m /testfs /newfs

After executing the above command /newfs renamed as /testfs

We can auto mount the file system while booting using chfs command

#chfs –A /testfs

AIX - LVM - Create File System

Create FS

Using crfs command we can create a file system. File systems belongs to LV’s

Whenever we create the file system we should mention the LV name

#crfs –v jfs2 –d testlv –m /newfs (Normal creation)

The /newfs file system created on testlv.

#crfs –v jfs2 –g testvg –a size=64465 –m /newfs (Directly we can create /fs from VG
This case lv name will be lv00 or lv01 like this after that also we can rename the lv name)


IBM - AIX - List File System

We can list file system details using lsfs command

#lsfs – List all filesystems in the /etc/filesystems entry

#lsfs –q (List all filesystems with detailed info)

#lsfs –a (list all filesystems (default)

#lsfs –l (specify the output in the list format)

#lsfs –c (specify the output in the column format)

#lsfs –v jfs (List all jfs filesystems)

AIX - LVM - Mount File System
After creating the file system, we should mount the file system, without file system mount we cannot access the file system using mount command we can mount the file system.

Before mount lsfs command is wont display the /newfs file system

#lsfs –a

That /newfs file system detail is not available

#mount /newfs

Now you execute lsfs command, it will show the /newfs details

#lsfs –a

No comments:

Post a Comment