Resize a VNF deployed in Openstack

Please make sure that your VNF files system was created through LVM (Logical Volume Manager). to identify this you use the following command $ cat /etc/fstab
This is an exmaple of fixed FS, which you can not resize
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
UUID=9d956232-4e00-4976-a6c6-207a757342bf /               ext4    errors=remount-ro 0       1
While this is an example of FS initiated through LVM, which you can resize
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
/dev/mapper/MasterDebain-root/ /               ext4    errors=remount-ro 0       1
you can use fdisk a command to resize a machine.
$ df -h
image
$ fdisk -l
image
$ fdisk /dev/vda/
image
Command (m for help): n
Command action
   e   extended
   p   primary (1 primary, 1 extended, 2 free)
Select (default p): p
Partition Number (3-4, default 3): {enter}
First Sector (XXXXXX -XXXXXX, default XXXXX): {Enter}
Last Sector (XXXXXX -XXXXXX, default XXXXX): {Enter}

Created a new partition 3 of type 'Linux' and of and size of 72 GiB

Command (m for help): w
The partition table has been altered.
Syncing Disks.
$
fdisk -l
image
$ pvdisplay
image
$ pvcreate /dev/vd4
  Physical volume "/dev/vda4" successfully created
$ pvdisplay
image
$ vgdisplay
image
$ vgextend MasterDebain-vg /dev/vda4
  Volume group "MasterDebain-vg" successfully extended
$ vgdisplay
image
$ lvdisplay | grep Path
   LV Path    /dev/MasterDebain-vg/root
   LV Path    /dev/MasterDebain-vg/swap_1
   LV Path    /dev/MasterDebain-vg/home
now extend
$ lvextend -l +100%FREE /dev/MasterDebain-vg/root
  Extending logical volume MasterDebain-vg/root changed to 74.53 GiB
  Logical volume MasterDebain-vg/root successfully resized
We are almost done
$ resize2fs /dev/MasterDebain-vg/root
now again check the size of root directory
$ df -h
image
Enjoy ;)

Compile and Install Kamailio as IMS Node

Download latest release from Git
$ wget https://github.com/kamailio/kamailio/archive/5.3.1.tar.gz
Or clone it from git
$ git clone --depth 1 --no-single-branch --branch 5.3 https://github.com/kamailio/kamailio kamailio
Extract source
$ cd /usr/local/src/
$ tar -zxvf 5.3.1.tar.gz
$ cd kamailio-5.3.1/
Install dependencies
$ apt install flex bison gcc g++ libssl-dev libcurl4 libxml2 libpcre3 libxml2-dev libmnl-dev librabbitmq-dev libmediastreamer-dev libortp-dev libsctp-dev make libsystemd-dev libpcre3-dev libcurl3-gnutls-dev uuid-dev libsnmp-dev
Add IMS Modules and set installation directory to /opt/kamailio
$ make PREFIX="/opt/kamailio" include_modules="cdp cdp_avp db_mysql ims_auth ims_charging ims_dialog ims_diameter_server ims_icscf ims_ipsec_pcscf ims_isc ims_ocs ims_qos ims_registrar_pcscf ims_registrar_scscf ims_usrloc_pcscf ims_usrloc_scscf log_systemd rabbitmq regex rls sctp snmpstats utils uuid xmlrpc pua ims_ipsec_pcscf" cfg
Compile Kamailio
$ make Q=0 all
Install Kamailio
$ make install

if in case you need to re-compile a module use the following commands

$ make modules modules=modules/ims_qos
$ make install-modules modules=modules/ims_qos

For normal Kamailio installation, you can follow this link.


Enjoy ;)

Resize Virtual Box Machine


On host OS (Windows 10)

.\VBoxManage.exe modifyhd '..\..\..\Users\username\VirtualBox VMs\CSCF Node 2\CSCF Node 2.vdi' --resize 13000

On Guest OS (Debian)

$ fdisk -l
$ fdisk /dev/sda
$ fdisk -l
$ pvs
$ lvs
$ pvdisplay
$ fdisk -l
$ pvcreate /dev/sda4
$ pvdisplay
$ vgextend MasterDebain-vg /dev/sda4
$ pvdisplay
$ lvdisplay
$ lvextend -l +100%FREE /dev/MasterDebain-vg/root
$ resize2fs /dev/MasterDebain-vg/root

Please follow this link.


Hamid Raza Hashmi hamid.hashmi006@gmail.com +92 300 968 22 85

How to compile and run a next application ?

Install nodejs Use  this  link for further reading curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.0/install.sh | bash nvm inst...