SOLVED cloudatcost debian install not using all diskspace?

hecatae

resident hecatae
Joined
Feb 7, 2014
Messages
759
Reaction score
199
Code:
The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sun May  1 14:02:23 2016
root@xivo:~# df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/dm-0       9.1G  1.8G  6.8G  21% /
udev             10M     0   10M   0% /dev
tmpfs           503M  7.1M  496M   2% /run
tmpfs           1.3G  4.0K  1.3G   1% /dev/shm
tmpfs           5.0M     0  5.0M   0% /run/lock
tmpfs           1.3G     0  1.3G   0% /sys/fs/cgroup
/dev/sda1       236M   33M  191M  15% /boot
root@xivo:~# fdisk -l

Disk /dev/sda: 39.1 GiB, 41943040000 bytes, 81920000 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
Disklabel type: dos
Disk identifier: 0x061e4152

Device     Boot    Start      End  Sectors  Size Id Type
/dev/sda1  *        2048   499711   497664  243M 83 Linux
/dev/sda2         501758 20969471 20467714  9.8G  5 Extended
/dev/sda3       20969472 81919999 60950528 29.1G 83 Linux
/dev/sda5         501760 20969471 20467712  9.8G 8e Linux LVM

Partition table entries are not in disk order.
Disk /dev/mapper/localhost--vg-root: 9.3 GiB, 9995026432 bytes, 19521536 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 /dev/mapper/localhost--vg-swap_1: 460 MiB, 482344960 bytes, 942080 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
root@xivo:~#

sda2, sda3 and sda5 are not mounted according to umount:

root@xivo:~# umount /dev/sda5
umount: /dev/sda5: not mounted
root@xivo:~# umount /dev/sda2
umount: /dev/sda2: not mounted
root@xivo:~# umount /dev/sda3
umount: /dev/sda3: not mounted

hello LVM, why you not been actioned?

root@fusionpbx:~# pvcreate /dev/sda3
Physical volume "/dev/sda3" successfully created
root@fusionpbx:~# vgextend localhost-vg /dev/sda3
Volume group "localhost-vg" successfully extended
root@fusionpbx:~# lvextend -L+29G /dev/localhost-vg/root
Size of logical volume localhost-vg/root changed from 9.31 GiB (2383 extents) to 38.31 GiB (9807 extents).
Logical volume root successfully resized
root@fusionpbx:~# resize2fs /dev/localhost-vg/root
resize2fs 1.42.12 (29-Aug-2014)
Filesystem at /dev/localhost-vg/root is mounted on /; on-line resizing required
old_desc_blocks = 1, new_desc_blocks = 3
The filesystem on /dev/localhost-vg/root is now 10042368 (4k) blocks long.

I'm going to have to do this for every c@c broken install...

borrowed the above from turnkeylinux https://www.turnkeylinux.org/blog/extending-lvm
 
Last edited:

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,159
Reaction score
5,192
Bummer! Maybe you should open a ticket. Looks like someone didn't quite get the image build right. :hang:
 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,159
Reaction score
5,192
For the time being, unless you want to go through this drill, limit your disk size to 10GB.
 

hecatae

resident hecatae
Joined
Feb 7, 2014
Messages
759
Reaction score
199
open a ticket?

they will just close it, strange thing is the ubuntu lvm script works perfectly, zang-ubuntu.sh
 

hecatae

resident hecatae
Joined
Feb 7, 2014
Messages
759
Reaction score
199
Code:
root@localhost:/mnt2# cat setup.sh
apt-get update
cp /mnt2/npasswd /bin/
chmod 777 /bin/npasswd
/bin/npasswd root password
/bin/npasswd user same as above
rm -rf /etc/network/interfaces
rm -rf /root/linux*
/etc/init.d/networking restart
cp /mnt2/interfac /etc/network/interfaces
/sbin/route add default gw 167.88.34.1
echo "nameserver 8.8.8.8" >/etc/resolv.conf
/etc/init.d/networking restart
rm -rf /root/linux*
echo 0>/etc/init.d/S97-setup.sh
chmod 600 /etc/init.d/S97-setup.sh
wget panel.cloudatcost.com/download/zang-debian.sh --no-check-certificate
chmod 755 zang-debian.sh
sh zang-debian.sh
echo 600 > /sys/block/sda/device/timeout
rm /etc/ssh/ssh_host_*
/usr/sbin/dpkg-reconfigure openssh-server
umount /dev/cdrom
echo 0>/root/.bash_history
echo 'test -f /etc/ssh/ssh_host_dsa_key || dpkg-reconfigure openssh-server'>>/etc/rc.local
echo "GRUB_RECORDFAIL_TIMEOUT=2" >> /etc/default/grub && update-grub
service sshd restart


zang-debian.sh is here:

Code:
vgscan
lvscan
lastpart=`fdisk -l /dev/sda | grep sda |tail -1 |awk '{ print $1 }' |grep -o "[0-9]"`
newpart=`expr $lastpart + 1`
startsec=`parted /dev/sda unit s print free |tail -2 |grep Free |awk '{ print $1 }'`
endsec=`parted /dev/sda unit s print free |tail -2 |grep Free |awk '{ print $2 }'`
parted -s /dev/sda mkpart primary ext2 $startsec $endsec
parted -s /dev/sda set $newpart lvm on
partx -v -a /dev/sda
pvcreate /dev/sda$newpart
vgname=`vgdisplay |grep "VG Name" |awk '{ print $3 }'`
vgextend $vgname /dev/sda$newpart
lvPath=`lvdisplay |grep "LV Path" |grep -v swap |awk '{ print $3 } '`
lvextend -l+100%FREE $lvPath
resize2fs $lvPath
 

classicalmusic

New Member
Joined
Apr 21, 2015
Messages
28
Reaction score
13
The steps and tutorials in this thread were always a goto when experimenting with WAZO and using CloudatCost broken Debian images. Thank you!!

It appears they have fixed their images. In the last 4 weeks I've built a number of Debian services at CatC without the storage issue. The storage amount you specify is actually being used as shown by using the command df -h .
 

Members online

No members online now.

Forum statistics

Threads
25,770
Messages
167,441
Members
19,181
Latest member
ejrubin
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top