VyOS is an operating system that is derived on Debian.
This manual will show you how to expand the disk space on a server that is running the vyOS operating system.
Setting
Please note that Vyos superuser mode is required for all subsequent tasks.
sudo su
First, use the fdisk command to list all currently installed disks:
fdisk -l
Disk /dev/sda: 32.2 GB, 32212254720 bytes 255 heads, 63 sectors/track, 3916 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x000b4645 Device Boot Start End Blocks Id System /dev/sda1 * 1 1306 10484736 83 Linux
Then you must read the expanded disk size again:
echo 1 > /sys/block/sda/device/rescan
Run fdisk:
fdisk -u -c /dev/sda
Then, proceed as directed by the fdisk command interface. Use the d option to eliminate the sole remaining partition:
Command (m for help): d
Selected partition 1
With the n option, create a new partition on vyos:
Command (m for help): n
Choose type – main:
Command action
l logical (5 or over)
p primary partition (1-4)
p
Specify number:
Partition number (1-4): 1
By default, when the Enter key is pressed, the start and end of the occupied space are selected:
First sector (XXX-YYY, default ZZZ):
Last sector, +sectors or +size{K,M,G} (XXX-YYY, default ZZZ):
This manual will show you how to expand the disk space on a server that is running the vyOS operating system.
Setting Note: Vyos superuser mode is required for all subsequent tasks.
Suto do
First, use the fdisk command to list all currently installed disks:
fdisk + L
Disk /dev/sda: 32212254720 bytes, 32.2 GB
3916 cylinders, 63 sectors per track, and 255 heads
cylinders of 16065 by 512, or 8225280 bytes, are the units.
Sector size: 512 bytes/512 bytes (logical/physical).
I/O size: 512 bytes / 512 bytes (minimum/optimal)
Name of the disk: 0x000b4645
Device Boot Start End Blocks Id System 1306 10484736 /dev/sda1 * 1 Linux
Then you must read the expanded disk size again:
[code]
echo 1 > /system/block/sda/device/rescan
[/code]
Start fdisk:
[code]
/dev/sda, fdisk -u, -c
[/code]
Then, proceed as directed by the fdisk command interface. Use the d option to eliminate the sole remaining partition:
Command (m for assistance):
opted for partition 1
Make a new partition on vyos with the n option:
Command (for assistance): n
Select type — main:
Command action logical (five or more) main (one to four)
Give a number:
(1-4) Partition number: 1
By default, when the Enter key is pressed, the start and end of the occupied space are selected:
Last sector, +sectors, or +size K, M, G (XXX-YYY, default ZZZ): First sector (XXX-YYY, default ZZZ):
The file system on the newly created partition will then be modified using the t option:
Command: t Selected partition 1 (m for help).
enter the Linux file system’s hexadecimal code:
Type L to list codes in hexadecimal, 83
To save your modifications and close the utility, use the w option.
(M for assistance): w
There has been a change to the partition table!
ioctl() is used to read the partition table again.
WARNING: Error 16 prevented the partition table from being read again. Device or resource is occupied.
The old table is still used by the kernel. When you reboot your computer or after using partprobe(8) or kpartx(8) to synchronize your disks, the updated table will be put to use.
Restarting the server will notify the kernel of the modifications you’ve made:
now /sbin/shutdown -r
Use the SSH protocol to reconnect to it with superuser privileges.
To inform the kernel that the partition table has changed, issue the following command:
[code]
element /dev/sda
[/code]
Set the file system size next:
[code]
/dev/sda1 resize2fs
[/code]
The df command can be used to verify the changes:
df -h
The disk space on VyOS has been expanded.
Command (m for help): t
Selected partition 1
enter the Linux file system’s hexadecimal code:
Hex code (type L to list codes): 83
To save your modifications and close the utility, use the w option.
Command (m for help): w
There has been a change to the partition table! ioctl() is used to read the partition table again. WARNING: Error 16 prevented the partition table from being read again. Device or resource is occupied. The old table is still used by the kernel. When you reboot your computer or after using partprobe(8) or kpartx(8) to synchronize your disks, the updated table will be put to use.
Restarting the server will notify the kernel of the modifications you’ve made:
/sbin/shutdown -r now
Use the SSH protocol to reconnect to it with superuser privileges.
To inform the kernel that the partition table has changed, issue the following command:
partx /dev/sda
Set the file system size next:
resize2fs /dev/sda1
The df command can be used to verify the changes:
df -h
The disk space on VyOS has been expanded.
Welcome to the world of DomainRooster, where roosters (and hens) rule the roost! We're a one-stop shop for all your entrepreneurial needs, bringing together domain names and website hosting, and all the tools you need to bring your ideas to life. With our help, you'll soar to new heights and hatch great success. Think of us as your trusty sidekick, always there to lend a wing and help you navigate the sometimes-complex world of domain names and web hosting. Our team of roosters are experts in their fields and are always on hand to answer any questions and provide guidance. So why wait? Sign up today and join the ranks of the world's greatest entrepreneurs. With DomainRooster, the sky's the limit! And remember, as the saying goes, "Successful people do what unsuccessful people are not willing to do." So don't be afraid to take that leap of faith - DomainRooster is here to help you reach for the stars. Caw on!