- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Problem extending swap space
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 05:51 AM
06-18-2003 05:51 AM
Problem extending swap space
1) umount /DB_PP4
2) lvreduce -m 0 /dev/VG_PP/lvol4 /dev/dsk/c0t6d0 (primary disk)
3) lvremove /dev/VG_PP/lvol4 (original vol group)
4)vgreduce /dev/VG_PP /dev/dsk/c0t6d0
5)vgextend /dev/vg00 /dev/dsk/c0t6d0 (extend vg00 volumn group to use primary disk)
6) lvcreate -L 4000 /dev/vg00 (create lvol9 - swap)
My problem is what i do now? How do i add the second device to this new lvol and How do i mirror the new volumn group with the 2nd physical disk (/dev/dsk/c1t1d0)? i have tried lvextend -m 1 /dev/vg00/lvol9 /dev/dsk/c1t1d0 bu this does not work.
Also what then?? do i just add the additional swap space with swapon /dev/vg00/lvol9? or do i have to do something else?
Any help appreciated
Declan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:02 AM
06-18-2003 06:02 AM
Re: Problem extending swap space
sam > :Disks and File Systems> Swap > Action (menu) > Add Device Swap/Add File System Swap (menu item)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:04 AM
06-18-2003 06:04 AM
Re: Problem extending swap space
First, IMHO, you should have created a new VG for this swap. But let's proceed down the road you're on.
You need to add the other disk to vg00 that will mirror this secondary swap
vgextend vg00 /dev/dsk/c1t1d0
Then extend the swap LV to this new device
lvextend -m 1 /dev/vg00/lvol9 /dev/dsk/c1t1d0
Now edit the /etc/fstab file for this new swap device This insures it's enabled at all subsequent boots - add the following:
/dev/vg00/lvol9 ... swap pri=0 0 0
Then enable the new swap:
swapon -a
It's possible that you may need to extend some kernel parameters to allow this new swap space.
See maxswapchunks & swchunk
The system will tell you that you need to do this when you try to enable it. This will require a reboot.
HTH,
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:05 AM
06-18-2003 06:05 AM
Re: Problem extending swap space
This will do the mirroring. It will take a while to mirror 4GB though.
To activate the swap do;
1. add it into /etc/fstab;
/dev/vg00/lvol9 / swap defaults 0 0 # secondary swap
2. swapon -a
Thats it, all done!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:05 AM
06-18-2003 06:05 AM
Re: Problem extending swap space
there are a number of points:
- first: have you enough space left to mirror the swap on another phisycal disk ?
please post a "vgdisplay -v vg00"
- are your kernel parameter enough to host so much swap ?
please post your /stand/system
- when you created the lvol, did you specify the (-C y -M n) option to have it contiguos and with no mirrir write cache ? it looks like not...
- after that, you can use SAM to add the swap,
or add it by yourself editing the /etc/fstab and doing a "swapon -a"
HTH,
Massimo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:06 AM
06-18-2003 06:06 AM
Re: Problem extending swap space
If all you want to do is add a secondary swap, then don't add it to vg00. It would be better to add it to another volume group and leave vg00 as a single physical disk volume group.
On a non-vg00 volume group, create a secondar device swap and set its swap priority to 0 so that is is used in preference to primary swap:
# lvcreate -C y -r n -L
# swapon -p 0 /dev/vgXX/lvolN
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:07 AM
06-18-2003 06:07 AM
Re: Problem extending swap space
Basically, now that your lvol has been created all you need to do to enable your swap is
#swapon /dev/vg00/lvol9
And that should activate your swap. It is probably a good idea to also include the Lvol in your /etc/fstab with something like that :
/dev/vg00/lvol9 ... swap pri=2 0 0
So that it starts your swap on this lvol every time you boot.
As for mirroring this swap : I do not know how many disks are in your VG00 at this point, but once your lvol is created, all you need to do is :
#lvextend -m 1 /dev/vg00/lvol9 /dev/dsk/mirrordisk
where mirrordisk would be the exact filename of the disk you plan to use and have your mirror on to.
Since you are using c1t1d0 as your mirrordisk, it should work, now what error message did it gave you when you tried this command?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:19 AM
06-18-2003 06:19 AM
Re: Problem extending swap space
You have two questions:
1. How do I mirror LVs?
2. How do I add swap?
2. Extend swap:
lvcreate -C y -r n -n swap02 vg00 # create swap volume
# Contiguous
# No bad block reloction
lvextend -L 1996 /dev/vg00/swap02 /dev/dsk/c5t9d0 # assign to 2nd disk
# modify /etc/fstab
echo "/dev/vg00/swap02 ... swap pri=2 0 0" >> /etc/fstab
# turn swap on..
swapon -a # all /etc/fstab swap
4. If there was a file system on this LV before, you must:
swapon -f /dev/vg00/swap02
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:21 AM
06-18-2003 06:21 AM
Re: Problem extending swap space
lvextend -m 1 /dev/vg00/lvol9 /dev/dsk/c1t1d0
both return the message;
vgextend: "/dev/dsk/c1t1d0": No such file or directory
lvextend: "/dev/dsk/c1t1d0": No such file or directory
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:31 AM
06-18-2003 06:31 AM
Re: Problem extending swap space
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:33 AM
06-18-2003 06:33 AM
Re: Problem extending swap space
I haven't seen anything in your post about adding /dev/dsk/c0t1d1 in vg00. To be used as a mirror for lvol9 it must be first one of the disks of vg00, so yoy have to vgextend first.
Regards.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:35 AM
06-18-2003 06:35 AM
Re: Problem extending swap space
You need to determine just what that device is - run:
ioscan -funC disk
And determine just *what* the device for that 2nd 8Gb disk is.
Then you *may* need to initialize it:
pvcreate /dev/rdsk/cXtYdZ
you may need -f to force the init - but be DARN sure of the proper device because this WILL destroy any LVM info on that device.
Then just follow the steps as laid out earlier using the proper device.
HTH,
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:42 AM
06-18-2003 06:42 AM
Re: Problem extending swap space
#ioscan -fnC disk
will show you which disks are seen by your system. If some filenames are missing, maybe even a
#insf -e
would help.
Again, as already mentionned, if you do a pvcreate, MAKE SURE that the disk is not already used for another purpose. And also, make it is already part of VG00. Then you can lvextend.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 06:47 AM
06-18-2003 06:47 AM
Re: Problem extending swap space
I think you have hit the nail on the head -/dev/dsk/c1t1d0 is not appearing in my ioscan as a disk although i was sure that was the dev that was mirroring my original VG (now trashed to make the additional swap). I'll have to go back a few steps and try and find the 2nd disk before continuing. I'll post an update of my progress and assign points as soon as i've worked out what i'm doing.
Thanks for the replies
Declan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-18-2003 07:19 AM
06-18-2003 07:19 AM
Re: Problem extending swap space
Thanks for all the assistance
Points assigned
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-20-2003 02:11 AM
06-20-2003 02:11 AM
Re: Problem extending swap space
Thanks again
Declan