Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
create_ubuntu_templates [2018/05/19 12:29] 5.155.173.110 |
create_ubuntu_templates [2018/07/03 21:20] (current) orwah |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | creating Ubuntu based VM Template | + | ====== creating Ubuntu based VM Template ====== |
Mainly you will need to create Ubuntu VM manually and then do the following steps to the template before converting it to Template | Mainly you will need to create Ubuntu VM manually and then do the following steps to the template before converting it to Template | ||
Line 48: | Line 48: | ||
- | </code> <wrap hi>Note: the sizes are not important</wrap> | + | </code> __Note:__ the sizes are not important |
- | * now we need to make scripts run automatically on system startup , | + | |
- | - Ordered List Item | + | |
- | from xenica package get the script files (xenica_assign_ip,xenica_auostart.sh) and put inside /etc/ | + | * **now we need to make scripts run automatically on system startup** , |
+ | get the script file: xenicastart.sh from your xenica package (or you can get it from [[HERE]]) and put inside /etc/ | ||
so that you will have the file locations as follows | so that you will have the file locations as follows | ||
- | <code>/etc/xenica_assign_ip.sh | + | <code>/etc/xenicastart.sh</code> |
- | /etc/xenica_auostart.sh | + | |
- | </code> | + | |
assign the executable mode to the file by the command | assign the executable mode to the file by the command | ||
- | <code>chmod +x /etc/xenica_assign_ip.sh | + | <code>chmod +x /etc/xenicastart.sh</code> |
- | chmod +x /etc/xenica_auostart.sh</code> | + | |
Open the file /etc/rc.local in edit mode and put the line | Open the file /etc/rc.local in edit mode and put the line | ||
- | <code>/etc/xenica_assign_ip.sh | + | <code>/etc/xenicastart.sh</code> |
- | /etc/xenica_auostart.sh</code> | + | |
inside /etc/rc.local | inside /etc/rc.local | ||
Line 75: | Line 72: | ||
/dev/xvda2 501758 16775167 8136705 5 Extended | /dev/xvda2 501758 16775167 8136705 5 Extended | ||
</code>in my case it was 16775167 (the end of /dev/xvda2 partition) | </code>in my case it was 16775167 (the end of /dev/xvda2 partition) | ||
- | * now open the script at /etc/xenica_assign_ip.sh<code> | + | * now open the script at /etc/xenicastart.sh and edit the line |
- | and edit the line | + | <code>(echo n; echo p; echo 3; echo 16775168; echo ; echo t; echo 3; echo 8e; echo w) | fdisk -u /dev/xvda</code> |
- | (echo n; echo p; echo 3; echo 16775168; echo ; echo t; echo 3; echo 8e; echo w) | fdisk -u /dev/xvda | + | to the number you got in step 5 +1 |
- | to the number you got in step 5 +1</code> | + | |
* convert to template | * convert to template | ||