Shrinking and growing a logical volume in Fedora 15

During my Fedora 15 installation, i made two Logical Volumes, HomeLV 50GB for /home and RootLV 5GB for /. This was a mistake and very soon the / was full.

[root@localhost ~]# df -h /
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/FedVG-RootLV
4.8G  4.5G  4.9G  94% /

So i now wanted to shrink the /home and extend the /.

To reduce a logical volume. We first need to reduce the filesystem on it using resize2fs or fsadm. Then use lvresize (or lvreduce) to resize the logical volume.

[root@localhost ~]# resize2fs /dev/mapper/FedVG-HomLV 45G
resize2fs 1.41.14 (22-Dec-2010)
Filesystem at /dev/mapper/FedVG-HomLV is mounted on /home; on-line resizing required
resize2fs: On-line shrinking not supported

Online shrinking is not supported. So now the option is to unmount the underlying filesystem ie, /home. For that i had to logout of the GNOME and work in a Virtual console (Ctrl+Alt+F[1-6]).

Now, a bit more reading of the man page of lvresize and i found that by using -r switch, we can resize the underlying  filesystem  together with the logical volume.

[root@localhost ~]# umount /dev/mapper/FedVG-HomLV
[root@localhost ~]# lvresize -r -L -5G /dev/mapper/FedVG-HomLV
fsck from util-linux2.19.1
dev/mapper/FedVG-HomLV: 900/2949120 files (1.2% non-contiguous), 250200/11796480 blocks

resize2fs 1.41.14 (22-Dec-2010)
Resizing the filesystem on /dev/mapper/FedVG-HomLV to 10977280 (4k) blocks.
The filesystem on /dev/mapper/FedVG-HomLV is now 10977280 blocks long.

Reducing logical volume HomLV to 41.88 GiB
Logical volume HomLV successfully resized

The -L switch with +/-nG directs lvresize it to add or reduce n GB.

[root@localhost ~]# mount /home
[root@localhost ~]# df -h /home
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/FedVG-HomLV
42G  253M   39G   1% /home

 

The next step is to extend the RootLV logical volume and then grow the root filesystem.

[root@localhost ~]# lvextend -l +100%FREE /dev/mapper/FedVG-RootLV
Extending logical volume RootLV to 10.00 GiB
Logical volume RootLV successfully resized

The +100%FREE option directs the lvextend to use the available free extents(free space). Note that the -r switch to resize the underlying filesystem is available here too though i didnt use it.

Grow the filesystem using resizefs. By default, most file system resizing tools will increase the size of the file system to be the size of the underlying logical volume so you do not need to worry about specifying the same size for each of the two commands.

[root@localhost ~]# resize2fs /dev/mapper/FedVG-RootLV
resize2fs 1.41.14 (22-Dec-2010)
Filesystem at /dev/mapper/FedVG-RootLV is mounted on /; on-line resizing required
old desc_blocks = 1, new_desc_blocks = 1
Performing an on-line resize of /dev/mapper/FedVG-RootLV to 2621440 (4k) blocks.
The filesystem on /dev/mapper/FedVG-RootLV is now 2621440 blocks long.

Online growing of filesystem is supported although online shrinking not supported as we saw earlier.

[root@localhost ~]# df -h /
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/FedVG-RootLV
9.9G  4.5G  4.9G  48% /

Fedora 15 in SONY VAIO VPC CB 15FG

Model name: Sony VAIO VPCCB15FG

Hardware
Intel Core i5 2410 @ 2.30ghz
Intel HM 65 Express chipset
4GB RAM, 500GB 7200 Toshiba HD
Hybrid graphics AMD Radeon 6630M 1GB DDR3 VRAM / Intel HD 3000
Matshita DVD RW, 15.5” 1920×1080 Full HD WLED screen
ATHEROS WLAN and Ethernet
Realtek Audio, Exmor 1.3MP webcam
HDMI and VGA output. 1 USB 3.0

Installation
Install Media: Fedora 15 64bit DVD

Installation went smooth.
This is the state just after installation,

Sound: Works. Recording: Works.
External monitor via VGA and HDMI: Works in both extended and mirrored fashion. You can use both LCD and external monitor, or LCD ON and external OFF in either mirrored or extended fashion, by using the accelerator buttons. But i couldn’t find a way to switch off the LCD and use only the external monitor.
Accelerator Buttons: Sound+/-, mute, screen brightness+/-, Screen->External monitor, hibernate works. Touchpad On/off and Zoom buttons dont work.
Atheros WLAN: Works. ON/OFF switch: Works.
Atheros Ethernet: Not tested.
Bluetooth: *Not working*. Bluetooth settings show ‘device disabled’
USB 2.0/3.0: Works.
Card Reader: Not tested.
Touchpad: Works fine. Mouse clicks and two finger scrolling works after enabling in the GNOME3 settings.
Webcam: Works.
DVD drive: To Do
Suspend: Works.
Hibernate: Works.

Hybrid graphics: Fedora 15 includes vgaswitchroo module and switching OFF the Radeon card manually works fine. However, when switching to the Radeon from the integrated card, GNOME3 fails to load.

To switch off the Radeon card use the command,

[root@localhost ~]# echo OFF > /sys/kernel/debug/vgaswitcheroo/switch

It can be confirmed whether the card is switched OFF by checking the remaining battery time before and after that command. There will be a difference of ~1.5hrs.

Some issues
Fedora comes with a default Radeon driver. However this seems to have a problem and sometimes during boot the system hangs at “dracut : starting plymouth deamon”. I found a dirty solution read here

As GNOME3 doesnt work with Radeon driver. No 3D support available.

Screen brightness gets reset to maximum after every restart.

..

For those who are interested here is the lspci of the VPCCB15FG

[root@localhost ~]# lspci
00:00.0 Host bridge: Intel Corporation Sandy Bridge DRAM Controller (rev 09)
00:01.0 PCI bridge: Intel Corporation Sandy Bridge PCI Express Root Port (rev 09)
00:02.0 VGA compatible controller: Intel Corporation Device 0116 (rev 09)
00:16.0 Communication controller: Intel Corporation Cougar Point HECI Controller #1 (rev 04)
00:1a.0 USB Controller: Intel Corporation Cougar Point USB Enhanced Host Controller #2 (rev 04)
00:1b.0 Audio device: Intel Corporation Cougar Point High Definition Audio Controller (rev 04)
00:1c.0 PCI bridge: Intel Corporation Cougar Point PCI Express Root Port 1 (rev b4)
00:1c.1 PCI bridge: Intel Corporation Cougar Point PCI Express Root Port 2 (rev b4)
00:1c.2 PCI bridge: Intel Corporation Cougar Point PCI Express Root Port 3 (rev b4)
00:1c.3 PCI bridge: Intel Corporation Cougar Point PCI Express Root Port 4 (rev b4)
00:1d.0 USB Controller: Intel Corporation Cougar Point USB Enhanced Host Controller #1 (rev 04)
00:1f.0 ISA bridge: Intel Corporation Cougar Point LPC Controller (rev 04)
00:1f.2 SATA controller: Intel Corporation Cougar Point 6 port SATA AHCI Controller (rev 04)
00:1f.3 SMBus: Intel Corporation Cougar Point SMBus Controller (rev 04)
01:00.0 VGA compatible controller: ATI Technologies Inc Device 6741 (rev ff)
02:00.0 Network controller: Atheros Communications Inc. AR9285 Wireless Network Adapter (PCI-Express) (rev 01)
03:00.0 SD Host controller: Ricoh Co Ltd Device e823 (rev 04)
03:00.1 System peripheral: Ricoh Co Ltd Device e232 (rev 04)
04:00.0 USB Controller: NEC Corporation uPD720200 USB 3.0 Host Controller (rev 04)
05:00.0 Ethernet controller: Atheros Communications Device 1083 (rev c0)

My new laptop: SONY VAIO VPCCB15FG

Model Name: Sony VAIO VPC CB15FG

Sony VAIO VPC CB 15FGSony VAIO VPC CB 15 FG

Specs
2nd Gen Intel Core i5 2410 @ 2.30ghz
Intel HM 65 Express chipset
4GB RAM, 500GB 7200 Toshiba HD
Hybrid graphics AMD Radeon 6630M 1GB DDR3 VRAM / Intel HD 3000
Matshita DVD RW, 15.5” 1920×1080 Full HD WLED screen
ATHEROS WLAN and Ethernet
Realtek Audio, Exmor 1.3MP webcam
HDMI and VGA output. 1 USB 3.0

Backlit keyboard.
Automatic screen brightness control

Windows 7 Premium OS pre-installed. No DVD given.

Free Targus bag(not backpack) worth 1.3k

Price: 53600/-

My few bits
Full HD Screen is fantastic if you want a lot of screen space. However the font size will be a bit too small. I like large fonts and less strain on eye, so increased DPI settings to 125%.
The island keyboard includes a numpad and is the best i’ve used. Very very nice!!
Touchpad is sometimes less responsive. Not the best in the class.
Sound is alright. Not too good or bad.
Includes a wireless ON/OFF switch.
Heat dissipation seems good. There are many air vents at the bottom. Normal operating temp is 45-48C (Room Temp ~25C). After two hours of gaming(FIFA) it came to 71C max.
I found the automatic brightness control irritating and disabled it very soon.
Hybrid graphics is really cool! Greatly helps to maximise battery life (a diff of 1.5hrs) and minimize heat when you dont need 3D acceleration.
HDMI output is fine so that you can connect to your large HD TV for gaming and movies.
Build Quality seems fine. But its an all plastic body, no metal even at this price.

Booting for the first time
Upon booting for the first time there were some bloatwares installed. Removed them all and created rescue DVD’s. These are required in case for reinstalling windows, as no Windows 7 DVD is given.

There was only one drive (C:) with all the available diskspace.

DiskManagement showed 3 partitions. One recovery and system protection partition (may be for system restore) which are hidden and the visible C Drive.

Tried to shrink this drive using the DiskManagement. But it was only possible to shrink it to 200 something GB. Tried shrinking after de-fragmenting, but still the same result.

Finally used GParted from an Ubuntu Live CD. GParted allows non-destructive shrinking of partitions including NTFS. Reduced the drive to 50GB. GParted has a nice easy to use GUI and is available for download as a Live CD. This is a howto on how to resize a partition.
When you boot back to Windows after modifying partitions with GParted, windows’ checkdisk check the disks for inconsistency. Allow it to complete and you are fine.

Created some more partition using the Windows 7 DiskManagement.

Performance
I have’nt done anything intensive yet. However it seems i5 is good enough for almost anything. I have had 20-25 tabs opened in FF without any problem. The Windows 7 Experience Index gives a 6.9 for the processor and 6.4 for the gaming graphics, in a scale of 1.0 to 7.9.

Gaming
AMD HD 6630M seems good for casual gaming. The left side of the touchpad gets bit hot after sometime.
The maximum system temperature i got after 2hrs of FIFA was 71C. Seems fine.

Tried my favourite game FIFA 11 @ 1920×1080, connected to an external monitor via VGA. With all the settings set to max i got a frame rate of ~42FPS during gameplay. The frame rate drops considerably during replays (20-35).
Barcelona Vs Real Madrid @ 1080. FPS and screenshot using Fraps.

FIFA 11 gameplay @ 1080 in Radeon 6630MFIFA 11 Replay @ 1080 Radeon 6630M

FIFA 11 @ 1366×768 with all the settings set to max gives you 60FPS. Note that this is the maximum FPS for an LCD panel, the card must be capable for more. There will be slight blur at this resolution (noticeable if you compare with a 1080 pic) but excellent framerate.
Barcelona Vs Real Madrid @ 768. FPS and screenshot using Fraps.

FIFA 11 gameplay @ 766 Radeon 6630M

Battery
Battery life seems to be decent. Without the Radeon On, its shows about 4hrs+ during idle. And when the Radeon is on it there will be a 1.5hrs difference.

Firefox 3.6 crashing X Server in CentOS 5.3

I recently did a yum update firefox. This caused my FF to be updated to 3.6 from the earlier 3.0.
Very soon i noticed that while browsing certain sites, i was getting logged out from the X server. The FF seemed to crash my X server.

One such site was this: http://wiki.centos.org/HowTos/VNC-Server

A quick google search reveals that this is a known issue with the the video driver.
The solution was to update the CentOS to the latest 5.5.

However, a quick fix can be done,
Add the following line to the ‘Device‘ section of your xorg.conf file (/etc/X11/xorg.conf).
Option    "XAANoOffscreenPixmaps" "true"
Restart X by Ctrl-Alt-Backspace

Check out the problem page again.

In some computers it might also be required to add this line too
Option     "AccelMethod" "XAA"

GROUND ZERO by 13AD

13AD was one of India’s top most rock bands from the 80’s to the mid 90’s. This band was playing in a hotel called “Sea Lord” in Kochi, Kerala, India.

They released two albums, “Ground Zero” and “Tough on the Streets” in the 90’s, before breaking up in 1995.

Album cover of GROUND ZERO

The Band
(1) Vocals – Glen La’Rive (Till 1993)
(2) Vocals – George Peter
(3) Lead & rhythm guitars – Eloy Isaacs
(4) Bass guitar – Paul K.J
(5) Keyboards – Jackson Aruja
(6) Drums – Pinson Correa

Audio release by Magna Sound

Check here for more info about the band and songs.

Credits to my uncle Taj who got these songs from an old Cassette.
This is copied from an old cassette so the quality may not be that great.
(Any suggestions to improve the quality is welcome)


TRACK LISTING
(All songs in .mp3 format. Right click and ‘Save Target As‘)

Bad Taste
Ground Zero
Desolate Prisoner
Your Company
Down Deep

Won’t give up
Revelation
Fortune’s Domain
Can’t make up my mind
City Blues
Rocking in Faith

All songs in a .zip file (46.2MB)