Posted on June 26, 2014 at 12:22 pm
First you need to create a NFS Virtual Disk Storage via XenCenter.
Then select a VM, open the “Storage” tab in XenCenter, and click the button “Add…”:
Then you should see the virtual disk present in the list of virtual disks:
The virtual disk is now attached and active in the virtual machine.
Connect to the virtual machine via SSH and type:
fdisk -l |
And you should identify the recently attached disk /dev/xvdc:
Disk /dev/xvdc: 1073 MB, 1073741824 bytes 255 heads, 63 sectors/track, 130 cylinders, total 2097152 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Disk /dev/xvdc doesn't contain a valid partition table |
If you try to mount the disk /dev/xvdc you will get this error message:
root@127.0.0.1:~# mount /dev/xvdc /mnt -t auto mount: you must specify the filesystem type |
You need to assign the filesystem to the disk, type this command:
mkfs.ext3 /dev/xvdc 2>/dev/null |
This is an example output:
Filesystem label= OS type: Linux Block size=4096 (log=2) Fragment size=4096 (log=2) Stride=0 blocks, Stripe width=0 blocks 131072 inodes, 524288 blocks 26214 blocks (5.00%) reserved for the super user First data block=0 Maximum filesystem blocks=536870912 16 block groups 32768 blocks per group, 32768 fragments per group 8192 inodes per group Superblock backups stored on blocks: 32768, 98304, 163840, 229376, 294912 Allocating group tables: done Writing inode tables: done Creating journal (16384 blocks): done Writing superblocks and filesystem accounting information: done |
Now you can finally mount the disk:
root@127.0.0.1:~# mount /dev/xvdc /mnt -t auto root@127.0.0.1:~# |
The new disk is mounted in /mnt path.
Updated on November 19, 2016 at 12:05 pm
Other Posts
- Block Paltalk Ads (and Others) via Hosts file
- E: Sub-process /usr/bin/dpkg returned an error code (2)
- How to Validate JSON in PHP
- The program can’t start because VCRUNTIME140.DLL is missing
- PHP CURL Download Remote URL to File
- PHP Check if a file was modified more than 1 hour ago
- Linux -bash: Input/output error or -bash: Read-only file system
- Dropzone.js: Drag’n’Drop File Uploads with Image Previews
Updated Posts
- Lost connection during Debian apt-get upgrade
- Bootstrap 3 Navbar with Logo Image
- Redis HMGET, HGETALL, HSET, HGET Benchmark
- PHP GetHostByName() Slow? Make it Faster
- Use Timestamp with new DateTime() in PHP
- Calculate Elapsed Time Between Two Dates in PHP
- PHP Display Date Same as Server HTTP Headers Date
- PHP cURL Download Size Limit