LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 05-02-2013, 05:04 AM   #1
sburnay
LQ Newbie
 
Registered: Sep 2011
Location: Lisbon, Portugal
Distribution: Ubuntu, CentOS & SUSE
Posts: 26

Rep: Reputation: Disabled
Managing Disks and Partitions


Hi,

I have an Ubuntu.12.04 64bit server VM which I have created with a single 60GB Virtual Disk:
Code:
root@myServer:~# df -h
Filesystem              Size  Used Avail Use% Mounted on
/dev/mapper/argus-root   58G  2.9G   52G   6% /
udev                    992M  4.0K  992M   1% /dev
tmpfs                   401M  340K  400M   1% /run
none                    5.0M     0  5.0M   0% /run/lock
none                   1001M     0 1001M   0% /run/shm
/dev/sda1               228M   25M  192M  12% /boot
I have no experience in managing partitions nor manipulating fileSystems, still, I added this VM two disks:
  1. one for logs - 7GB, where I'd like to point /var/log/
  2. and other for the MySQL databases - 20GB, where I'd like to point /var/lib/mysql

I have added those disks using the VMware Player's GUI and they are correctly associated with my ubuntu VM.

I just didn't understand
  1. why are the disks not listed with the df command,
  2. nor how to make them be recognized
  3. and more importantly, how will I map the mentioned parts of my actual FileSystem to these new disks
I began following some instructions and found those two drives were '/dev/sdb' and '/dev/sdc', both with:
Code:
Disk identifier: 0x00000000
Disk /dev/sdc doesn't contain a valid partition table
For each drive I've done:
  1. mkfs.ext4 /dev/sdb
  2. chmod -R 777 <mounting point>
  3. mount /dev/sdb <mounting point>
And afterwords I've edited /etc/fstab and added an entry for each drive:
Code:
root@argus:~# cat /etc/fstab
# /etc/fstab: static file system information.
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    nodev,noexec,nosuid 0       0
/dev/mapper/argus-root /               ext4    errors=remount-ro 0       1
# /boot was on /dev/sda1 during installation
UUID=0daeb714-1f37-46db-9ab2-a469cfb36e5d /boot           ext2    defaults        0       2
/dev/mapper/argus-swap_1 none            swap    sw              0       0
/dev/fd0        /media/floppy0  auto    rw,user,noauto,exec,utf8 0       0
/dev/sdb        /var/lib/mysql  ext4    defaults        0       0
/dev/sdc        /var/log        ext4    defaults        0       0
How do I make sure my changes were successfully implemented? Do I have to copy a large file to one of the mountingpoints and check if the refpective assigned drive's ocupation is increasing?

Thank you very much
 
Old 05-02-2013, 05:09 AM   #2
pan64
Senior Member
 
Registered: Mar 2012
Location: Hungary
Distribution: debian i686 (solaris)
Posts: 4,928

Rep: Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305
it looks ok. You can try to reboot (restart) your VM. and you will need to see /var/log and /var/lib/mysql again. Also you can try to put some small files on them to check if it works, but I think it should be ok.
 
1 members found this post helpful.
Old 05-02-2013, 05:14 AM   #3
sburnay
LQ Newbie
 
Registered: Sep 2011
Location: Lisbon, Portugal
Distribution: Ubuntu, CentOS & SUSE
Posts: 26

Original Poster
Rep: Reputation: Disabled
Yes, it seems done.

I've sent a 700MB .iso to /var/log, and the respective entry in 'df -h' acused the extra ocupation rate from it.

I'm just not understanding howcome the uoutput of fdisk -l:
Code:
...
Disk identifier: 0x00000000

Disk /dev/sdc doesn't contain a valid partition table
...
Why were these drives not given an identifier and why does the system complain about the validity of partition tables?

Is it because these drives are not partitioned?

Last edited by sburnay; 05-02-2013 at 05:18 AM.
 
Old 05-02-2013, 05:16 AM   #4
pan64
Senior Member
 
Registered: Mar 2012
Location: Hungary
Distribution: debian i686 (solaris)
Posts: 4,928

Rep: Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305Reputation: 1305
so you solved yourself, that is great. Just please mark thread solved.
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
question on managing disk partitions mz043 Linux - Newbie 6 03-29-2007 11:42 AM
Managing disks and partitions in Suse 10 cvzyl Linux - Hardware 2 07-30-2006 02:30 AM
managing external disks with Veritas Elec490 Solaris / OpenSolaris 1 09-06-2005 02:18 AM
managing partitions sakman Linux - Newbie 2 06-24-2005 09:52 PM
Managing Multiple Partitions and OS's Echo Kilo Linux - Software 0 10-22-2004 11:28 AM


All times are GMT -5. The time now is 08:15 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration