https://wiki.amahi.org/api.php?action=feedcontributions&user=Dforbes&feedformat=atomAmahi Wiki - User contributions [en]2024-03-28T13:47:53ZUser contributionsMediaWiki 1.34.2https://wiki.amahi.org/index.php?title=Amahi_Time_Machine&diff=46999Amahi Time Machine2011-10-07T23:11:54Z<p>Dforbes: Created page with "This page contains advanced hints and tips on using the Amahi Time Machine app. Unless otherwise stated, the commands listed on this page need to be run with root privileges and..."</p>
<hr />
<div>This page contains advanced hints and tips on using the Amahi Time Machine app. Unless otherwise stated, the commands listed on this page need to be run with root privileges and therefore extreme care should be taken.<br />
<br />
= Limit backup volume size =<br />
By default, Apple's Time Machine software will grow the backup size to use all available disk space. To artificially limit this, do the following.<br />
<br />
1. Edit the file /etc/netatalk/AppleVolumes.default:<br />
On the line that begins '/var/hda/files/amahi-time-machine', add 'volsizelimit:XXXX' AFTER 'options:tm', where XXXX is the artificial limit in MiB.<br />
<br />
2. Execute 'service netatalk restart'<br />
<br />
NOTE: do not do this while a backup is running. The way Apple's Time Machine software works requires more disk space than the size of the backup available. It is usually best to put a volume size limit in place before the first backup is created.</div>Dforbeshttps://wiki.amahi.org/index.php?title=VPN&diff=45931VPN2011-08-27T09:34:23Z<p>Dforbes: </p>
<hr />
<div>Remote VPN access to your Amahi HDA comes pre-configured out of the box. There is nothing to configure in the server.<br />
<br />
'''You need to forward one port (1194/UDP) to your HDA's IP''' to enable the VPN.<br />
<br />
You will also need a client software.<br />
<br />
Once connected from outside your network, your computer becomes virtually a computer in your home network. All your files and services are as easily accessible as when you are at home.<br />
<br />
'''NEW! You can now use your amahi.org [https://www.amahi.org/user control panel] to test your VPN remotely!'''<br />
<br />
= Overview =<br />
<br />
There are two requirements for Remote Access to work:<br />
<br />
* On the client side, you need to be running a client<br />
** We provide one for Windows, pre-configured for Amahi<br />
** We recommend one for the Mac, which requires some manual configuration<br />
** The client for Linux comes with most distros and uses the same settings as the Mac<br />
* Your router needs to forward '''UDP port 1194''' to the IP address of your HDA. The way to do this is through port forwarding, which varies from router to router. Make sure you forward UDP (not TCP)<br />
<br />
= Clients For Windows, Mac, Linux, Android, iPhone, ... =<br />
<br />
Check the page for [[VPN clients]].<br />
<br />
= Resources on Port Forwarding =<br />
<br />
* [http://www.portforward.com/english/routers/port_forwarding/routerindex.htm Massive database of port forwarding information by router]<br />
* YouTube Video on Port Forwarding for Linksys Routers: http://www.youtube.com/watch?v=GWPUdW1kIJA<br />
<br />
= Bridging VPN and eth0 =<br />
<br />
Ff you'd like your VPN clients to get IP addresses in the same subnet as your HDA, and not in the 10.8.0.0/24 subnet (default), read this page: [[VPN Bridging]].<br />
<br />
= Troubleshooting =<br />
* Make sure your HDA's network IP range is different than that of the remote network. (e.g. if your HDA's IP address is 192.168.1.X, you cannot connect to it on a remote network also using 192.168.1.X)<br />
<br />
* If you are running your HDA from a Verizon FiOS connection, you may experience strange disconnections. This may be due to the Actiontec router's small NAT table. Please see guides here http://www.verizonfioswiki.com/index.php/Using_Your_Own_Router for instructions on how to use your own router.<br />
<br />
* If you have a Vonage V-Portal (or perhaps other voip adapters as well), plug your router into your modem, then the v-portal into your router. Vonage tells you to put the v-portal between the modem and the router, but I was unable to connect to vpn until I moved the adapter behind the router.<br />
<br />
* Check out [[VPN_troubleshooting]] for more troubleshooting tips.<br />
<br />
= Implementation =<br />
<br />
The VPN solution is implemented through the very popular [http://openvpn.net/ OpenVPN] software VPN.<br />
<br />
= Alternative VPN solutions =<br />
In addition to the [http://openvpn.net/ OpenVPN] solution described above, there is an implementation of an [http://www.amahi.org/apps/ipsec-vpn IPsec VPN] available as an App. There are a number of advantages to this solution, including iPhone compatibility (without jail-breaking).<br />
<br />
[[Category: Services]]<br />
[[Category: VPN]]</div>Dforbeshttps://wiki.amahi.org/index.php?title=IPsec_VPN&diff=45925IPsec VPN2011-08-27T09:27:21Z<p>Dforbes: </p>
<hr />
<div>We now have a new [http://www.amahi.org/apps/ipsec-vpn IPsec VPN] app for your HDA.<br />
<br />
This VPN stack has many advantages, although it still requires two ports to be forwarded from your router to your HDA. These are<br />
<br />
'''500 UDP''' and '''4500 UDP'''<br />
<br />
UDP, not TCP.<br />
<br />
Below is how to set up clients for various client operating systems.<br />
<br />
= iOS Setup =<br />
<br />
Go to Settings > Network > VPN > IPSec, enter the settings below and click on Save.<br />
<br />
* Description: Amahi IPSec VPN<br />
* Server: YOURNICK.yourhda.com (put your Amahi dyndns address, nickname and host)<br />
* Account: USERNAME<br />
* Password: leave it as "Ask Every Time" or put one if you feel it's safe to leave it there<br />
* Use Certificate: leave it as OFF<br />
* Group Name: Amahi (with a capital A)<br />
* Secret: this is the 4-character you got the when you installed the IPSec VPN app in your HDA<br />
* Proxy: leave it as off<br />
<br />
Below you can see how the setup area looks in a few Apple iOS devices.<br />
<br />
== iPad ==<br />
<br />
It should look something like this on the [http://www.apple.com/ipad/ iPad 2], iOS 4.x<br />
<br />
[[Image:IPSec VPN iPad 2.png]]<br />
<br />
== iPhone 3, iPod Touch ==<br />
<br />
It should look something like this on the [http://www.apple.com/iphone/iphone-3gs/ iPhone 3], iOS 4.x<br />
<br />
[[Image:IPSec VPN iPhone 3.png]]<br />
<br />
= Windows 7 =<br />
<br />
Currently, Amahi only supports one IPSec VPN client for windows, a free client from Shrew Soft. (Report others that also work well please)<br />
<br />
* Download and install the [http://www.shrew.net/download/vpn/vpn-client-2.2.0-beta-2.exe Shrew Soft Client]. (Their [http://www.shrew.net/download/vpn Windows VPN Client download page] may have more recent versions.)<br />
* Open the client, called '''VPN Access Manager''' and click on + (Add) to add a configuration<br />
* Enter '''YOURNICK.yourhda.com'''. Replace YOURNICK with your actual HDA nickname, so that your DynDNS works.<br />
<br />
[[Image:IPSec VPN Win7.png]]<br />
<br />
* Go into the Authentication tab<br />
* Select '''Mutual PSK + XAuth'''<br />
* Under the Local Identity tab, select Key Identifier, enter Amahi (this is called the Group Name and acts as an extra layer of protection)<br />
<br />
[[Image:IPSec VPN Win7 Client.png]]<br />
<br />
* In the Credentials tab, the Pre Shared Key should be ready to take the VPN secret obtained in the VPN web page inside your HDA.<br />
* The rest of things should work as default<br />
* Save<br />
<br />
[[Image:IPSec VPN Win7 Client Credentials.png]]<br />
<br />
* Finally click on connect or double click on the profile for your VPN<br />
* Input your username and password for a user in your Amahi HDA<br />
<br />
[[Image:IPSec VPN Win7 Client Connect.png]]<br />
<br />
* If all goes well, you should be connected and you should see this welcome message:<br />
<br />
[[Image:IPSec VPN Win7 Client Connected.png]]<br />
<br />
* Press OK. To disconnect, close this window or press on Disconnect.<br />
<br />
* For easy use, these are the recommended settings<br />
* Enable it to be visible in the Tray only, so that it's less obtrusive when it connects<br />
* If this is a computer you trust, you may want to also set the "remember the connection username", for even easier use <br />
<br />
[[Image:IPSec VPN Win7 Client Preferences.png]]<br />
<br />
= Max OS X Setup =<br />
<br />
Similar to iOS.<br />
<br />
* Open System Preferences > Network<br />
* Click on the '''+''' sign to create a new service<br />
* For Interface select '''VPN''. For VPN type select '''Cisco IPSec'''. Give the service a name, like '''Amahi Home''' and click on Create<br />
* Once added, select it. In the Server Address put '''YOURNICK.yourhda.com''' (replace YOURNICK with your nickname).<br />
* In Account Name, put your username. Leave password empty unless you trust this computer.<br />
* Click on Authentication Settings<br />
* In Shared Secret, put the Group Setting from your internal IPSec VPN. In Group Name, enter '''Amahi'''. Click OK<br />
* You can now click on Connect to connect!<br />
* You can also click on "Show VPN status in menu bar" for quick access to the VPN connection<br />
* Click on Apply to save these settings<br />
<br />
<br />
[[Category:Apps]]<br />
<br />
= Advanced Topics =<br />
Note: this section requires editing files with root privileges and restarting the racoon daemon. <br />
<br />
== Changing the Pre-Shared Key ==<br />
The pre-shared key is stored in the file /etc/racoon/psk.txt. If you want to customise it for any reason, simply edit the file with your favourite text editor and restart racoon. You will need to manually update all of your clients. Note that the web page at http://ipsec-vpn will not be updated.<br />
<br />
== Routing all network traffic via the VPN ==<br />
By default, the VPN will only route traffic destined for your home network via the VPN. General web traffic etc, will *not* be encrypted. To change this behaviour so that all network traffic from your client is routed via your VPN, edit /etc/racoon/racoon.conf and remove the lines beginning "split_network" and "split_dns". The restart racoon.</div>Dforbeshttps://wiki.amahi.org/index.php?title=Browse_and_Netboot_ISO_images&diff=34513Browse and Netboot ISO images2011-02-22T19:28:27Z<p>Dforbes: </p>
<hr />
<div>== Overview ==<br />
<br />
If you use Amahi to regularly download ISO images of operating systems and such like, this page is for you. It describes some tweaks that can be made to an Amahi setup to enable easy browsing and netbooting of ISO images, *without* having to mount each one and copy files. This is particularly handy, if you just want to try out the latest and greatest version of something.<br />
<br />
Almost every command in this article needs to be executed with root privileges. Therefore, use "su" to become root before you begin, or prefix each command with sudo if you prefer.<br />
<br />
== Part 1 - Making ISO images browsable ==<br />
<br />
First, we're going to use the automounter together with /dev/loop to mount the ISO files on demand. Before we can go any further, ensure that you have the automounter installed:<br />
<br />
{{Code|<br />
Code=yum -y install autofs<br />
}}<br />
<br />
Next, create a suitable mount point. In this example, we're using /media/iso-fs<br />
{{Code|<br />
Code=mkdir -p /media/iso-fs<br />
}}<br />
<br />
Now create a file called /media/.iso-fs.map using your favourite editor with the following contents:<br />
{{Code|<br />
Code=#!/bin/bash<br />
DIR_LIST=(/var/hda/files/torrents /home/*/Downloads)<br />
iso=`find ${DIR_LIST[@]} -name $1.iso -type f`<br />
echo "-fstype=iso9660 :$iso"<br />
}}<br />
This script will act as an executable mount map for the automounter, returning suitable mount point parameters if it finds an ISO file that matches the key passed to it.<br />
<br />
...and ensure that this file is executable:<br />
{{Code|<br />
Code=chmod u+x /media/.iso-fs.map<br />
}}<br />
<br />
The final step is to create an entry in the master automount map. Edit /etc/auto.master and add the following line somewhere after the default /net entry:<br />
<br />
{{Code|<br />
Code=/media/iso-fs /media/.iso-fs.map ro,loop --timeout=5<br />
}}<br />
<br />
The last parameter is the time in seconds after which a mount point will be automatically unmounted. Now restart the automounter with:<br />
<br />
{{Code|<br />
Code=service autofs restart<br />
}}<br />
<br />
If all has gone well, then you should be able to browse any ISO image that you have in your torrents or downloads directories. In my case, I have ubuntu-10.10-desktop-i386.iso in my torrents directory, so I get:<br />
{{Code|<br />
Code=bash$ ls /media/iso-fs/ubuntu-10.10-desktop-i386/<br />
autorun.inf dists md5sum.txt preseed usb-creator.exe<br />
boot install pics README.diskdefines wubi.exe<br />
casper isolinux pool ubuntu<br />
}}<br />
<br />
You can browse around the directories, copy files etc at leisure, and when you're done the automounter will release the loop device for reuse.<br />
<br />
== Part 2 - Making ISO images bootable ==<br />
First, we need to create some directories to hold the PXE menu structure and the script to generate it:<br />
{{Code|<br />
Code=cd /usr/share/amahi-netboot/tftp<br />
mkdir iso-boot<br />
mkdir iso-boot/conf<br />
mkdir iso-boot/mnt<br />
}}<br />
<br />
Next you will need to download [[File:menu-gen.sh]] to generate the PXE boot menus. Save this script as iso-boot/menu-gen.sh and make it executable:<br />
<br />
{{Code|<br />
Code=chmod u+x iso-boot/menu-gen.sh<br />
}}<br />
<br />
menu-gen.sh contains a number of configuration variables at the top; you will need to edit HDA_IP to match the IP address of your HDA at the very least. The TIMEOUT variable also needs to match the automount timeout set in part one so that your machine doesn't run out of loop devices.<br />
<br />
Now run the script to generate the menus based on the ISOs on your system and the distributions the script knows about:<br />
{{Code|<br />
Code=iso-boot/menu-gen.sh<br />
}}<br />
Note that the script will appear to run slowly as it waits for each ISO to time out before moving on to the next one.<br />
<br />
The last stage in setting up the menus, we need to add an entry in pxelinux.cfg/default to link to the generated menus. Open pxelinux.cfg/default in your favourite editor and add:<br />
{{Code|<br />
LABEL linux-boot<br />
MENU LABEL Boot from ISO images<br />
kernel menu.c32<br />
append iso-boot/conf/boot.conf<br />
}}<br />
<br />
With the menus created, we just have two final steps to take. First, the kernel and initrd need to be available under the tftp directory structure. Fortunately, the automounter can take care of this for us; simply add the following additional to /etc/auto.master:<br />
<br />
{{Code|<br />
Code=/usr/share/amahi-netboot/tftp/iso-boot/mnt /media/.iso-fs.map ro,loop --timeout=5<br />
}}<br />
...and then restart the automounter:<br />
{{Code|<br />
Code=service autofs restart<br />
}}<br />
<br />
Secondly, we need to enable NFS and export the relevant directories. Assuming you have NFS installed and running, edit /etc/exports to add:<br />
{{Code|<br />
Code=/media 192.168.147.0/24(ro,crossmnt)<br />
}}<br />
And then issue service nfs restart to load the new export table.<br />
<br />
== Known Issues ==<br />
#The menu-gen.sh script doesn't currently work for some images, notably those based on the dracut system<br />
#menu-gen.sh is a first attempt; it currently needs to be taught about new distributions and where to find the kernel and initrd image on each type of ISO. Suggestions and improvements to make it smarter greatly appreciated.<br />
#Occasionally, if you don't shutdown the PXE booted system cleanly, the automounter is unable to release the mount point</div>Dforbeshttps://wiki.amahi.org/index.php?title=Browse_and_Netboot_ISO_images&diff=34507Browse and Netboot ISO images2011-02-22T19:13:25Z<p>Dforbes: </p>
<hr />
<div>== Overview ==<br />
<br />
If you use Amahi to regularly download ISO images of operating systems and such like, this page is for you. It describes some tweaks that can be made to an Amahi setup to enable easy browsing and netbooting of ISO images, *without* having to mount each one and copy files. This is particularly handy, if you just want to try out the latest and greatest version of something.<br />
<br />
Almost every command in this article needs to be executed with root privileges. Therefore, use "su" to become root before you begin, or prefix each command with sudo if you prefer.<br />
<br />
== Part 1 - Making ISO images browsable ==<br />
<br />
First, we're going to use the automounter together with /dev/loop to mount the ISO files on demand. Before we can go any further, ensure that you have the automounter installed:<br />
<br />
{{Code|<br />
Code=yum -y install autofs<br />
}}<br />
<br />
Next, create a suitable mount point. In this example, we're using /media/iso-fs<br />
{{Code|<br />
Code=mkdir -p /media/iso-fs<br />
}}<br />
<br />
Now create a file called /media/.iso-fs.map using your favourite editor with the following contents:<br />
{{Code|<br />
Code=#!/bin/bash<br />
DIR_LIST=(/var/hda/files/torrents /home/*/Downloads)<br />
iso=`find ${DIR_LIST[@]} -name $1.iso -type f`<br />
echo "-fstype=iso9660 :$iso"<br />
}}<br />
This script will act as an executable mount map for the automounter, returning suitable mount point parameters if it finds an ISO file that matches the key passed to it.<br />
<br />
...and ensure that this file is executable:<br />
{{Code|<br />
Code=chmod u+x /media/.iso-fs.map<br />
}}<br />
<br />
The final step is to create an entry in the master automount map. Edit /etc/auto.master and add the following line somewhere after the default /net entry:<br />
<br />
{{Code|<br />
Code=/media/iso-fs /media/.iso-fs.map ro,loop --timeout=5<br />
}}<br />
<br />
The last parameter is the time in seconds after which a mount point will be automatically unmounted. Now restart the automounter with:<br />
<br />
{{Code|<br />
Code=service autofs restart<br />
}}<br />
<br />
If all has gone well, then you should be able to browse any ISO image that you have in your torrents or downloads directories. In my case, I have ubuntu-10.10-desktop-i386.iso in my torrents directory, so I get:<br />
{{Code|<br />
Code=bash$ ls /media/iso-fs/ubuntu-10.10-desktop-i386/<br />
autorun.inf dists md5sum.txt preseed usb-creator.exe<br />
boot install pics README.diskdefines wubi.exe<br />
casper isolinux pool ubuntu<br />
}}<br />
<br />
You can browse around the directories, copy files etc at leisure, and when you're done the automounter will release the loop device for reuse.<br />
<br />
== Part 2 - Making ISO images bootable ==<br />
First, we need to create some directories to hold the PXE menu structure and the script to generate it:<br />
{{Code|<br />
Code=cd /usr/share/amahi-netboot/tftp<br />
mkdir iso-boot<br />
mkdir iso-boot/conf<br />
mkdir iso-boot/mnt<br />
}}<br />
<br />
Next you will need to download [[File:menu-gen.sh]] to generate the PXE boot menus. Save this script as iso-boot/menu-gen.sh and make it executable:<br />
<br />
{{Code|<br />
Code=chmod u+x iso-boot/menu-gen.sh<br />
}}<br />
<br />
menu-gen.sh contains a number of configuration variables at the top; you will need to edit HDA_IP to match the IP address of your HDA at the very least. The TIMEOUT variable also needs to match the automount timeout set in part one so that your machine doesn't run out of loop devices.<br />
<br />
<br />
<br />
<br />
<br />
<br />
=== Known Issues ===<br />
#The menu-gen.sh script doesn't currently work for some images, notably those based on the dracut system<br />
#menu-gen.sh is a first attempt; it currently needs to be taught about new distributions and where to find the kernel and initrd image on each type of ISO. Suggestions and improvements to make it smarter greatly appreciated.<br />
#Occasionally, if you don't shutdown the PXE booted system cleanly, the automounter is unable to release the mount point</div>Dforbeshttps://wiki.amahi.org/index.php?title=Browse_and_Netboot_ISO_images&diff=34501Browse and Netboot ISO images2011-02-22T19:12:05Z<p>Dforbes: </p>
<hr />
<div>== Overview ==<br />
<br />
If you use Amahi to regularly download ISO images of operating systems and such like, this page is for you. It describes some tweaks that can be made to an Amahi setup to enable easy browsing and netbooting of ISO images, *without* having to mount each one and copy files. This is particularly handy, if you just want to try out the latest and greatest version of something.<br />
<br />
Almost every command in this article needs to be executed with root privileges. Therefore, use "su" to become root before you begin, or prefix each command with sudo if you prefer.<br />
<br />
== Part 1 - Making ISO images browsable ==<br />
<br />
First, we're going to use the automounter together with /dev/loop to mount the ISO files on demand. Before we can go any further, ensure that you have the automounter installed:<br />
<br />
{{Code|<br />
Code=yum -y install autofs<br />
}}<br />
<br />
Next, create a suitable mount point. In this example, we're using /media/iso-fs<br />
{{Code|<br />
Code=mkdir -p /media/iso-fs<br />
}}<br />
<br />
Now create a file called /media/.iso-fs.map using your favourite editor with the following contents:<br />
{{Code|<br />
Code=#!/bin/bash<br />
DIR_LIST=(/var/hda/files/torrents /home/*/Downloads)<br />
iso=`find ${DIR_LIST[@]} -name $1.iso -type f`<br />
echo "-fstype=iso9660 :$iso"<br />
}}<br />
This script will act as an executable mount map for the automounter, returning suitable mount point parameters if it finds an ISO file that matches the key passed to it.<br />
<br />
...and ensure that this file is executable:<br />
{{Code|<br />
Code=chmod u+x /media/.iso-fs.map<br />
}}<br />
<br />
The final step is to create an entry in the master automount map. Edit /etc/auto.master and add the following line somewhere after the default /net entry:<br />
<br />
{{Code|<br />
Code=/media/iso-fs /media/.iso-fs.map ro,loop --timeout=30<br />
}}<br />
<br />
The last parameter is the time in seconds after which a mount point will be automatically unmounted. Now restart the automounter with:<br />
<br />
{{Code|<br />
Code=service autofs restart<br />
}}<br />
<br />
If all has gone well, then you should be able to browse any ISO image that you have in your torrents or downloads directories. In my case, I have ubuntu-10.10-desktop-i386.iso in my torrents directory, so I get:<br />
{{Code|<br />
Code=bash$ ls /media/iso-fs/ubuntu-10.10-desktop-i386/<br />
autorun.inf dists md5sum.txt preseed usb-creator.exe<br />
boot install pics README.diskdefines wubi.exe<br />
casper isolinux pool ubuntu<br />
}}<br />
<br />
You can browse around the directories, copy files etc at leisure, and when you're done the automounter will release the loop device for reuse.<br />
<br />
== Part 2 - Making ISO images bootable ==<br />
First, we need to create some directories to hold the PXE menu structure and the script to generate it:<br />
{{Code|<br />
Code=cd /usr/share/amahi-netboot/tftp<br />
mkdir iso-boot<br />
mkdir iso-boot/conf<br />
mkdir iso-boot/mnt<br />
}}<br />
<br />
Next you will need to download [[File:menu-gen.sh]] to generate the PXE boot menus. Save this script as iso-boot/menu-gen.sh and make it executable:<br />
<br />
{{Code|<br />
Code=chmod u+x iso-boot/menu-gen.sh<br />
}}<br />
<br />
menu-gen.sh contains a number of configuration variables at the top; you will need to edit HDA_IP to match the IP address of your HDA at the very least. The TIMEOUT variable also needs to match the automount timeout set in part one so that your machine doesn't run out of loop devices.<br />
<br />
<br />
<br />
<br />
<br />
<br />
=== Known Issues ===<br />
#The menu-gen.sh script doesn't currently work for some images, notably those based on the dracut system<br />
#menu-gen.sh is a first attempt; it currently needs to be taught about new distributions and where to find the kernel and initrd image on each type of ISO. Suggestions and improvements to make it smarter greatly appreciated.<br />
#Occasionally, if you don't shutdown the PXE booted system cleanly, the automounter is unable to release the mount point</div>Dforbeshttps://wiki.amahi.org/index.php?title=File:Menu-gen.sh&diff=34495File:Menu-gen.sh2011-02-22T18:58:38Z<p>Dforbes: Bash script to generate PXE menu</p>
<hr />
<div>Bash script to generate PXE menu</div>Dforbeshttps://wiki.amahi.org/index.php?title=Browse_and_Netboot_ISO_images&diff=34489Browse and Netboot ISO images2011-02-22T18:57:22Z<p>Dforbes: </p>
<hr />
<div>== Overview ==<br />
<br />
If you use Amahi to regularly download ISO images of operating systems and such like, this page is for you. It describes some tweaks that can be made to an Amahi setup to enable easy browsing and netbooting of ISO images, *without* having to mount each one and copy files. This is particularly handy, if you just want to try out the latest and greatest version of something.<br />
<br />
Almost every command in this article needs to be executed with root privileges. Therefore, use "su" to become root before you begin, or prefix each command with sudo if you prefer.<br />
<br />
== Part 1 - Making ISO images browsable ==<br />
<br />
First, we're going to use the automounter together with /dev/loop to mount the ISO files on demand. Before we can go any further, ensure that you have the automounter installed:<br />
<br />
{{Code|<br />
Code=yum -y install autofs<br />
}}<br />
<br />
Next, create a suitable mount point. In this example, we're using /media/iso-fs<br />
{{Code|<br />
Code=mkdir -p /media/iso-fs<br />
}}<br />
<br />
Now create a file called /media/.iso-fs.map using your favourite editor with the following contents:<br />
{{Code|<br />
Code=#!/bin/bash<br />
DIR_LIST=(/var/hda/files/torrents /home/*/Downloads)<br />
iso=`find ${DIR_LIST[@]} -name $1.iso -type f`<br />
echo "-fstype=iso9660 :$iso"<br />
}}<br />
This script will act as an executable mount map for the automounter, returning suitable mount point parameters if it finds an ISO file that matches the key passed to it.<br />
<br />
...and ensure that this file is executable:<br />
{{Code|<br />
Code=chmod u+x /media/.iso-fs.map<br />
}}<br />
<br />
The final step is to create an entry in the master automount map. Edit /etc/auto.master and add the following line somewhere after the default /net entry:<br />
<br />
{{Code|<br />
Code=/media/iso-fs /media/.iso-fs.map ro,loop --timeout=30<br />
}}<br />
<br />
The last parameter is the time in seconds after which a mount point will be automatically unmounted. Now restart the automounter with:<br />
<br />
{{Code|<br />
Code=service autofs restart<br />
}}<br />
<br />
If all has gone well, then you should be able to browse any ISO image that you have in your torrents or downloads directories. In my case, I have ubuntu-10.10-desktop-i386.iso in my torrents directory, so I get:<br />
{{Code|<br />
Code=bash$ ls /media/iso-fs/ubuntu-10.10-desktop-i386/<br />
autorun.inf dists md5sum.txt preseed usb-creator.exe<br />
boot install pics README.diskdefines wubi.exe<br />
casper isolinux pool ubuntu<br />
}}<br />
<br />
You can browse around the directories, copy files etc at leisure, and when you're done the automounter will release the loop device for reuse.<br />
<br />
== Part 2 - Making ISO images bootable ==<br />
First, we need to create some directories to hold the PXE menu structure and the script to generate it:<br />
{{Code|<br />
Code=cd /usr/share/amahi-netboot/tftp<br />
mkdir iso-boot<br />
mkdir iso-boot/conf<br />
mkdir iso-boot/mnt<br />
}}<br />
<br />
<br />
<br />
<br />
=== Known Issues ===<br />
#The script doesn't currently work for some images, notably those based on the dracut system<br />
#Occasionally, if you don't shutdown the PXE booted system cleanly, the automounter is unable to release the mount point</div>Dforbeshttps://wiki.amahi.org/index.php?title=Browse_and_Netboot_ISO_images&diff=34483Browse and Netboot ISO images2011-02-22T18:32:07Z<p>Dforbes: </p>
<hr />
<div>== Overview ==<br />
<br />
If you use Amahi to regularly download ISO images of operating systems and such like, this page is for you. It describes some tweaks that can be made to an Amahi setup to enable easy browsing and netbooting of ISO images, *without* having to mount each one and copy files. This is particularly handy, if you just want to try out the latest and greatest version of something.<br />
<br />
Almost every command in this article needs to be executed with root privileges. Therefore, use "su" to become root before you begin, or prefix each command with sudo if you prefer.<br />
<br />
== Part 1 - Making ISO images browsable ==<br />
<br />
First, we're going to use the automounter together with /dev/loop to mount the ISO files on demand. Before we can go any further, ensure that you have the automounter installed:<br />
<br />
{{Code|<br />
Code=yum -y install autofs<br />
}}<br />
<br />
Next, create a suitable mount point. In this example, we're using /media/iso-fs<br />
{{Code|<br />
Code=mkdir -p /media/iso-fs<br />
}}<br />
<br />
Now create a file called /media/.iso-fs.map using your favourite editor with the following contents:<br />
{{Code|<br />
Code=#!/bin/bash<br />
DIR_LIST=(/var/hda/files/torrents /home/*/Downloads)<br />
iso=`find ${DIR_LIST[@]} -name $1.iso -type f`<br />
echo "-fstype=iso9660 :$iso"<br />
}}<br />
This script will act as an executable mount map for the automounter, returning suitable mount point parameters if it finds an ISO file that matches the key passed to it.<br />
<br />
...and ensure that this file is executable:<br />
{{Code|<br />
Code=chmod u+x /media/.iso-fs.map<br />
}}<br />
<br />
The final step is to create an entry in the master automount map. Edit /etc/auto.master and add the following line somewhere after the default /net entry:<br />
<br />
{{Code|<br />
Code=/media/iso-fs /media/.iso-fs.map ro,loop --timeout=30<br />
}}<br />
<br />
The last parameter is the time in seconds after which a mount point will be automatically unmounted. Now restart the automounter with:<br />
<br />
{{Code|<br />
Code=service autofs restart<br />
}}<br />
<br />
If all has gone well, then you should be able to browse any ISO image that you have in your torrents or downloads directories. In my case, I have ubuntu-10.10-desktop-i386.iso in my torrents directory, so I get:<br />
{{Code|<br />
Code=bash$ ls /media/iso-fs/ubuntu-10.10-desktop-i386/<br />
autorun.inf dists md5sum.txt preseed usb-creator.exe<br />
boot install pics README.diskdefines wubi.exe<br />
casper isolinux pool ubuntu<br />
}}<br />
<br />
You can browse around the directories, copy files etc at leisure, and when you're done the automounter will release the loop device for reuse.</div>Dforbeshttps://wiki.amahi.org/index.php?title=Browse_and_Netboot_ISO_images&diff=34477Browse and Netboot ISO images2011-02-22T18:25:02Z<p>Dforbes: Created page with "== Overview == If you use Amahi to regularly download ISO images of operating systems and such like, this page is for you. It describes some tweaks that can be made to an Amahi..."</p>
<hr />
<div>== Overview ==<br />
<br />
If you use Amahi to regularly download ISO images of operating systems and such like, this page is for you. It describes some tweaks that can be made to an Amahi setup to enable easy browsing and netbooting of ISO images, *without* having to mount each one and copy files. This is particularly handy, if you just want to try out the latest and greatest version of something.<br />
<br />
Almost every command in this article needs to be executed with root privileges. Therefore, use "su" to become root before you begin, or prefix each command with sudo if you prefer.<br />
<br />
== Part 1 - Making ISO images browsable ==<br />
<br />
First, we're going to use the automounter together with /dev/loop to mount the ISO files on demand. Before we can go any further, ensure that you have the automounter installed:<br />
<br />
{{Code|<br />
Code=yum -y install autofs<br />
}}<br />
<br />
Next, create a suitable mount point. In this example, we're using /media/iso-fs<br />
{{Code|<br />
Code=mkdir -p /media/iso-fs<br />
}}<br />
<br />
Now create a file called /media/.iso-fs.map using your favourite editor with the following contents:<br />
{{Code|<br />
Code=#!/bin/bash<br />
DIR_LIST=(/var/hda/files/torrents /home/*/Downloads)<br />
iso=`find ${DIR_LIST[@]} -name $1.iso -type f`<br />
echo "-fstype=iso9660 :$iso"<br />
}}<br />
This script will act as an executable mount map for the automounter, returning suitable mount point parameters if it finds an ISO file that matches the key passed to it.<br />
<br />
...and ensure that this file is executable:<br />
{{Code|<br />
Code=chmod u+x /media/.iso-fs.map<br />
}}<br />
<br />
The final step is to create</div>Dforbeshttps://wiki.amahi.org/index.php?title=Backups&diff=20323Backups2010-11-02T20:00:08Z<p>Dforbes: </p>
<hr />
<div>You have several ways to do backups in your HDA. We break them in two: full disk (bare metal) backups, and periodic backups.<br />
<br />
They are all initiated by the client computer on to the server.<br />
<br />
= Full Disk "Bare Metal" Backups =<br />
<br />
Each HDA now includes the Personal Backup Appliance, or PBA, with the collaboration of the PBA leader, Roland Hui.<br />
<br />
[[PBA | PBA]] is an application to do hard disk clones, backups and restores.<br />
<br />
<br />
= Periodic File Backups =<br />
One of the ways to backup systems in your network is to use the operating-system provided backup service.<br />
[[Image:VistaBackups3.png | 150px | Vista Backups | align:right]]<br />
<br />
We have documented ways to do periodic backups in various platforms. If you have good suggestions on how to do that, please add them to this section of the wiki! (Or email it to us if you're wiki-shy)<br />
<br />
Note: To new users only the "Bare Metal" Backups will show in the [http://wiki.amahi.org/index.php/PBABackups Amahi Personal Backup] webpage all others will not show on this page.<br />
<br />
== Third-Party (Free) Backup Software ==<br />
There are a number of great backup programs out there that you can use absolutely free. Here is my list:<br />
#[http://www.educ.umu.se/~cobian/cobianbackup.htm Cobian Backup]<br />
#[http://www.runtime.org/driveimage-xml.htm DriveImage XML]<br />
#[http://www.areca-backup.org/index.php Areca Backup]<br />
#[http://thebackupmonkey.blogspot.com/ Bonkey]<br />
#[http://www.hiteksoftware.com/jaba/ JaBack]<br />
#[http://www.nasbackup.com/wiki/Introduction NasBackup]<br />
#[http://www.aboutmyip.com/AboutMyXApp/DeltaCopy.jsp DeltaCopy]<br />
#[http://www.allwaysync.com/ Allway Sync]<br />
#[http://www.gfi.com/backup-hm GFI Backup]<br />
#[http://backuppc.sourceforge.net/ BackupPC]<br />
#[http://synchronicity.sourceforge.net/ Create Synchronicity]<br />
#[http://www.uk-dissertation.com/ Dissertations]<br />
<br />
= Windows 7 Backups =<br />
How to needs to be completed. Go [[Win7Backups|here]] to update the page.<br />
<br />
= Windows Vista Backups =<br />
Here is a quick how to on doing [[VistaBackups | periodic file backups in Windows Vista to your HDA]].<br />
<br />
= Windows XP Backups =<br />
<br />
For XP Backups, visit the section for [[XPBackups | Windows XP]]<br />
<br />
= Ubuntu Backups =<br />
<br />
How to backup Ubuntu clients using Ubuntu's [[Sbackup | Simple Backup]].<br />
<br />
= Fedora Backups =<br />
<br />
To backup Fedora clients, the following are recommended:<br />
<br />
* [[fwbackups]], a desktop utility<br />
* [http://rsnapshot.org/ rsnapshot], a solution using rsync, with command line interface<br />
* for backing up your hda shares to usbdrive see [[Rsnapshot]] for an example setup.<br />
<br />
= Mac OS X =<br />
<br />
Mac OS X without Time Machine is not officially supported through automated HDA Backups at this time. <br />
You can, however, manually copy files to an HDA shared folder.<br />
<br />
== Backups with SuperDuper! ==<br />
<br />
Another backup solution is a program called [[SuperDuper!]], follow the link to see the steps and to find out about SuperDuper!.<br />
<br />
== Backups with SystemRescueCD ==<br />
<br />
Backups with [[SystemRescueCD_with_Mac_OS_X | SystemRescueCD]] have been reported that they work, more info can be found by visiting the link.<br />
<br />
== Backups with Time Machine ==<br />
<br />
=== SMB (Samba) ===<br />
<br />
'''WARNING - Hack ahead!''' For Time Machine smb users only.<br />
<br />
There is an unsupported way to enable using Mac OS X Time Machine to backup to your HDA. The [http://vowe.net/archives/008940.html Time Machine hack] is a one liner command to be typed in a terminal in Mac OS X:<br />
<br />
<code>defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1</code><br />
<br />
This will offer you the choice to backup to your HDA shares.<br />
<br />
It should be noted that mounting a directory from your HDA via NFS let's you use time machine without this hack.<br />
<br />
Needless to say, we're not advocating you backup your data like this, since Apple does not support this functionality. There are rumors that data corruption can occur if the size of the backup exceeds 2TB or if a large number of files, on the order of a million, are backed up. Because the exact conditions leading to data corruption are not well quantified, we do not recommend you backup like this.<br />
<br />
<br />
=== AFP ===<br />
<br />
For full time machine support in fedora, avahi(bonjour) and netatalk(afp) need to be installed<br />
<br />
Install [[http://wiki.amahi.org/index.php/AFP AFP]] and Avahi]<br />
<br />
<br />
*in Applevolume.default add <br />
<br />
<code>~/ "$u" allow:UserName rwlist:UserName,@users cnidscheme:cdb<br><br />
/var/hda/files/timemachine allow:UserName rwlist:UserName,@users cnidscheme:cdb options:usedots,upriv</code><br />
<br />
*Change UserName to your username and /var/hda/files/timemachine to your timemachine folder, the first line will also publish your homefolder to your mac but was necessary in my setup to work<br />
<br />
*then service avahi-daemon and atalk restart<br />
<br />
*the server will show up on your mac connect to the xserve afp server<br />
*on your mac open disk utility<br />
*make a new disk image with the max size on disk possible and name it Computername_ethernetmacadress.sparsebundle<br />
ex.<br />
MacBookProIcey_aa00bb11cc22.sparsebundle<br />
<br />
#use Journaled/case sensitive<br />
#name has to be Backup of ComputerName<br />
#and save it to the timemachine share<br />
[[File:Tm-sparsebundle.png|caption]]<br />
<br />
*timemachine image will grow when you synchronize but never larger than the max size<br />
*time machine will now find your amahi time capsule<br />
<br />
''Update: Recent versions of timemachine do not appear to respect the max size of the sparsebundle and will cheerfully fill up your disk. To fix this, you need a more recent version of netatalk (2.0.5+?), which has an option to tell fibs about the size of the disk, hence limiting timemachine's space consumption. Fedora 14 has netatalk 2.1.4...''<br />
<br />
= Using Symantec Backup Exec System Recovery 8.5 (Norton save & restore) =<br />
<br />
Symantec's [http://www.symantec.com/business/backup-exec-system-recovery-desktop-edition BESR] allows full system backup and restore (virtual and physical)from any hardware with restore to dissimilar hardware. Conversion from P2V or V2P can also be scheduled. Install BESR on all windows computers connected to HDA and route backup to a folder on the HDA. Remember to set permissions on destination folders. Activate VSS copy so any open files are captured, optional threatcon can be used to trigger a backup if a threat becomes widespread. <br />
Alternatively BESR can be installed on a central windows machine with agents deployed on all other windows and Linux machines and using the new Linux media server agent (replaces RALUS) backup directly on the Linux HDA. This way you maintain a catalogue of all backups and can trigger them from a central console.<br />
BESR is the enterprise windows standard for Backup and restore. Norton the consumer brand of Symantec have [http://www.symantec.com/norton/save-restore "Save & Restore"] I'm not overly familiar with this product but it replaces Norton "Ghost" in most markets. The GUI is exactly the same as BESR.<br />
<br />
BESR is only for windows machines connected to the HDA but is a great solution to protecting these machines and allows LIVE single pass backup and granular restore of files, saves doing an image and a file backup. Less space less time. An agent is available to backup Linux but another option is to boot the HDA on the recovery disk and create a cold image of the server.<br />
<br />
<br />
[[Category: Services]]</div>Dforbeshttps://wiki.amahi.org/index.php?title=Amahi_on_VirtualBox&diff=20143Amahi on VirtualBox2010-10-26T10:30:41Z<p>Dforbes: </p>
<hr />
<div>= Why do this? =<br />
<br />
If you want to test Amahi without upsetting your existing network configuration, one of the easiest ways of doing so is using a virtual machine. The following description applies to VirtualBox, version 3.2.10. It results in a functioning Amahi install that can be accessed both from the host machine and other VMs, including PXE-booting VM.<br />
<br />
= Prerequisites =<br />
<br />
* A working installation of VirtualBox<br />
* An [[Express CD]] image (this was tested with Amahi-5.4-Express-2.6-Beta-i386.iso)<br />
* A desire to do this!<br />
<br />
= The catch =<br />
<br />
The process is fractionally more complex than a standard Amahi install, because we need to tweak the VM network configuration part-way through.<br />
<br />
You will also need to know the IP address range that your version of VirtualBox uses for its "Host only" network type. Check the network configuration of the host system on Mac OS (and I expect Linux) there's an interface called "vboxnet0". At the time of writing, the default on Mac OS is 192.168.56.1.<br />
<br />
= Configure the hda =<br />
<br />
First, configure your amahi install in the usual way at the [http://www.amahi.org/user control panel]. You must use the IP address of the VirtualBox "Host only" interface as your gateway (in my case, 192.168.56.1). If you have already have Amahi on your network, you might wish to consider changing the home domain to something other than home.com.<br />
<br />
Make a note of the install code indicated.<br />
<br />
= Create the VM =<br />
Create a fresh VM in the usual VirtualBox way:<br />
<br />
* Name it as you see fit ("Amahi-test")<br />
* Select "Linux" and "Fedora" as the OS and version<br />
* Create a virtual disk for the installation: 8GB, dynamically sized should be sufficient<br />
<br />
Once you've created the VM, go to the settings window and do the following:<br />
<br />
* Check that the first network interface is configured as NAT<br />
* Under storage, attach the Express CD image as a CD<br />
<br />
= Run the installation =<br />
Start your VM and it will boot from the CD image. Work through the [[Express CD]] installer in the usual way, entering the install code that the amahi control panel gave created earlier. You will be asked to reboot a couple of times during the process. (During the first reboot you will have to disconnect the Express CD iso image, otherwise you'll get back to the installer menu.)<br />
<br />
Eventually, the console should show a text login prompt. At which point you should shut down the VM (either by sending the shutdown signal from VirtualBox or log in and issue the command).<br />
<br />
= Altering the VM network config =<br />
At this stage we are going to configure ''two'' network interfaces. Open the VirtualBox network settings window for your VM. Configure the first two adapters thus:<br />
<br />
* Adapter 1: Enabled, Attached to: Host-only Adapter, Name: vboxnet0<br />
* Adapter 2: Enabled, Attached to: NAT<br />
<br />
= Reconfiguring the system =<br />
Boot the VM and wait for the login prompt. Login as admin (default password: admin) and use su to become root. Using your favourite editor, create the file:<br />
<br />
<blockquote><pre>/etc/sysconfig/network-scripts/ifcfg-eth1</pre></blockquote><br />
<br />
with the contents:<br />
<br />
<blockquote><br />
<pre><br />
DEVICE=eth1<br />
BOOTPROTO=dhcp <br />
ONBOOT=yes<br />
</pre><br />
</blockquote><br />
<br />
Now we need to reconfigure the hda to ensure that it picks up the new network config, using the command hda-change-gw and the IP address of the host-only network. In my case:<br />
<br />
<blockquote><br />
<pre><br />
hda-change-gw 192.168.56.1<br />
</pre><br />
</blockquote><br />
<br />
This allows amahi to serve on the host-only network, eth0, while still having access to the wider internet through the eth1 NAT interface. (The latter is necessary if you want to install any apps, for instance.)<br />
<br />
Now reboot.<br />
<br />
= Test it =<br />
Wait until the VM comes back up and open a web browser. Browse to http://192.168.56.10/ should put up the usual Amahi log-in page. If not, something's gone wrong. You can also connect via ssh from the host if you don't want to use the VirtualBox console. <br />
<br />
Note that the DNS & DHCP will not be visible from the host system unless you alter the host system config. However, other VMs connected to the same host-only network will be able to use these services, including PXE-booting.<br />
<br />
= Other approaches to network config =<br />
Amahi will work behind VirtualBox NAT quite happily, but at the time of writing, VirtualBox port-forwarding doesn't play nicely with Amahi's network config. (Or at least it didn't for me.) NAT also won't permit two virtual machines communicating (e.g. for testing PXE-booting).<br />
<br />
If you want Amahi within the VM to serve other machines on your LAN, select bridged mode instead of NAT initially and don't alter the network config. (The basic install process will ''just work''.)</div>Dforbeshttps://wiki.amahi.org/index.php?title=Amahi_on_VirtualBox&diff=20137Amahi on VirtualBox2010-10-25T19:57:33Z<p>Dforbes: </p>
<hr />
<div>= Why do this? =<br />
<br />
If you want to test Amahi without upsetting your existing network configuration, one of the easiest ways of doing so is using a virtual machine. The following description applies to VirtualBox, version 3.2.10. It results in a functioning Amahi install that can be accessed both from the host machine and other VMs, including PXE-booting VM.<br />
<br />
= Prerequisites =<br />
<br />
* A working installation of VirtualBox<br />
* An express CD image (this was tested with Amahi-5.4-Express-2.6-Beta-i386.iso)<br />
* A desire to do this!<br />
<br />
= The catch =<br />
<br />
The process is fractionally more complex than a standard Amahi install, because we need to tweak the VM network configuration part-way through.<br />
<br />
You will also need to know the IP address range that your version of VirtualBox uses for its "Host only" network type. Check the network configuration of the host system on Mac OS (and I expect Linux) there's an interface called "vboxnet0". At the time of writing, the default on Mac OS is 192.168.56.1.<br />
<br />
= Configure the hda =<br />
<br />
First, configure your amahi install in the usual way at the [http://www.amahi.org/user control panel]. You must use the IP address of the VirtualBox "Host only" interface as your gateway (in my case, 192.168.56.1). If you have already have Amahi on your network, you might wish to consider changing the home domain to something other than home.com.<br />
<br />
Make a note of the install code indicated.<br />
<br />
= Create the VM =<br />
Create a fresh VM in the usual VirtualBox way:<br />
<br />
* Name it as you see fit ("Amahi-test")<br />
* Select "Linux" and "Fedora" as the OS and version<br />
* Create a virtual disk for the installation: 8GB, dynamically sized should be sufficient<br />
<br />
Once you've created the VM, go to the settings window and do the following:<br />
<br />
* Check that the first network interface is configured as NAT<br />
* Under storage, attach the Express CD image as a CD<br />
<br />
= Run the installation =<br />
Start your VM and it will boot from the CD image. Work through the installer in the usual way, entering the install code that the amahi control panel gave created earlier. You may be asked to reboot a couple of times during the process. (Note that if you get the initial CD install menu back, you need to disconnect the ISO image and then reboot again.)<br />
<br />
Eventually, the console should show a text login prompt. At which point you should shut down the VM (either by sending the shutdown signal from VirtualBox or log in and issue the command).<br />
<br />
= Altering the VM network config =<br />
At this stage we are going to configure ''two'' network interfaces. Open the VirtualBox network settings window for your VM. Configure the first two adapters thus:<br />
<br />
* Adapter 1: Enabled, Attached to: Host-only Adapter, Name: vboxnet0<br />
* Adapter 2: Enabled, Attached to: NAT<br />
<br />
= Reconfiguring the system =<br />
Boot the VM and wait for the login prompt. Login as admin (default password: admin) and use su to become root. Using your favourite editor, create the file:<br />
<br />
<blockquote><pre>/etc/sysconfig/network-scripts/ifcfg-eth1</pre></blockquote><br />
<br />
with the contents:<br />
<br />
<blockquote><br />
<pre><br />
DEVICE=eth1<br />
BOOTPROTO=dhcp <br />
ONBOOT=yes<br />
</pre><br />
</blockquote><br />
<br />
Now we need to reconfigure the hda to ensure that it picks up the new network config, using the command hda-change-gw and the IP address of the host-only network. In my case:<br />
<br />
<blockquote><br />
<pre><br />
hda-change-gw 192.168.56.1<br />
</pre><br />
</blockquote><br />
<br />
Now reboot.<br />
<br />
= Test it =<br />
Wait until the VM comes back up and open a web browser. Browse to http://192.168.56.10/ should put up the usual Amahi log-in page. If not, something's gone wrong. You can also connect via ssh from the host if you don't want to use the VirtualBox console. <br />
<br />
Note that the DNS & DHCP will not be visible from the host system unless you alter the host system config. However, other VMs connected to the same host-only network will be able to use these services, including PXE-booting.<br />
<br />
= Other approaches to network config =<br />
Amahi will work behind VirtualBox NAT quite happily, but at the time of writing, VirtualBox port-forwarding doesn't play nicely with Amahi's network config. (Or at least it didn't for me.) NAT also won't permit two virtual machines communicating (e.g. for testing PXE-booting).<br />
<br />
If you want Amahi within the VM to serve other machines on your LAN, select bridged mode instead of NAT initially and don't alter the network config. (The basic install process will ''just work''.)</div>Dforbeshttps://wiki.amahi.org/index.php?title=Amahi_on_VirtualBox&diff=20131Amahi on VirtualBox2010-10-25T19:12:06Z<p>Dforbes: </p>
<hr />
<div>= Why do this? =<br />
<br />
If you want to test Amahi without upsetting your existing network configuration, one of the easiest ways of doing so is using a virtual machine. The following description applies to VirtualBox, version 3.2.10. It results in a functioning Amahi install that can be accessed both from the host machine and other VMs, including PXE-booting VM.<br />
<br />
= Prerequisites =<br />
<br />
* A working installation of VirtualBox<br />
* An express CD image (this was tested with Amahi-5.4-Express-2.6-Beta-i386.iso)<br />
* A desire to do this!<br />
<br />
= The catch =<br />
<br />
The process is fractionally more complex than a standard Amahi install, because we need to tweak the VM network configuration part-way through.<br />
<br />
You will also need to know the IP address range that your version of VirtualBox uses for its "Host only" network type. Check the network configuration of the host system on Mac OS (and I expect Linux) there's an interface called "vboxnet0". At the time of writing, the default on Mac OS is 192.168.56.1.<br />
<br />
= Configure the hda =<br />
<br />
First, configure your amahi install in the usual way at the [http://www.amahi.org/user control panel]. You must use the IP address of the VirtualBox "Host only" interface as your gateway (in my case, 192.168.56.1). If you have already have Amahi on your network, you might wish to consider changing the home domain to something other than home.com.<br />
<br />
Make a note of the install code indicated.<br />
<br />
= Create the VM =<br />
Create a fresh VM in the usual VirtualBox way:<br />
<br />
* Name it as you see fit ("Amahi-test")<br />
* Select "Linux" and "Fedora" as the OS and version<br />
* Create a virtual disk for the installation: 8GB, dynamically sized should be sufficient<br />
<br />
Once you've created the VM, go to the settings window and do the following:<br />
<br />
* Check that the first network interface is configured as NAT<br />
* Under storage, attach the Express CD image as a CD<br />
<br />
= Run the installation =<br />
Start your VM and it will boot from the CD image. Work through the installer in the usual way, entering the install code that the amahi control panel gave created earlier. You may be asked to reboot a couple of times during the process. (Note that if you get the initial CD install menu back, you need to disconnect the ISO image and then reboot again.)<br />
<br />
Eventually, the console should show a text login prompt. At which point you should shut down the VM (either by sending the shutdown signal from VirtualBox or log in and issue the command).<br />
<br />
= Altering the VM network config =<br />
At this stage we are going to configure ''two'' network interfaces. Open the VirtualBox network settings window for your VM. Configure the first two adapters thus:<br />
<br />
* Adapter 1: Enabled, Attached to: Host-only Adapter, Name: vboxnet0<br />
* Adapter 2: Enabled, Attached to: NAT<br />
<br />
= Reconfiguring the system =<br />
Boot the VM and wait for the login prompt. Login as admin (default password: admin) and use su to become root. Using your favourite editor, create the file:<br />
<br />
<blockquote><pre>/etc/sysconfig/network-scripts/ifcfg-eth1</pre></blockquote><br />
<br />
with the contents:<br />
<br />
<blockquote><br />
<pre><br />
DEVICE=eth1<br />
BOOTPROTO=dhcp <br />
ONBOOT=yes<br />
</pre><br />
</blockquote><br />
<br />
Now we need to reconfigure the hda to ensure that it picks up the new network config, using the command hda-change-gw and the IP address of the host-only network. In my case:<br />
<br />
<blockquote><br />
<pre><br />
hda-change-gw 192.168.56.1<br />
</pre><br />
</blockquote><br />
<br />
Now reboot.<br />
<br />
= Test it =<br />
Wait until the VM comes back up and open a web browser. Browse to http://192.168.56.1/ should put up the usual Amahi log-in page. If not, something's gone wrong. You can also connect via ssh from the host if you don't want to use the VirtualBox console. <br />
<br />
Note that the DNS & DHCP will not be visible from the host system unless you alter the host system config. However, other VMs connected to the same host-only network will be able to use these services, including PXE-booting.<br />
<br />
= Other approaches to network config =<br />
Amahi will work behind VirtualBox NAT quite happily, but at the time of writing, VirtualBox port-forwarding doesn't play nicely with Amahi's network config. (Or at least it didn't for me.) NAT also won't permit two virtual machines communicating (e.g. for testing PXE-booting).<br />
<br />
If you want Amahi within the VM to serve other machines on your LAN, select bridged mode instead of NAT initially and don't alter the network config. (The basic install process will ''just work''.)</div>Dforbeshttps://wiki.amahi.org/index.php?title=Amahi_on_VirtualBox&diff=20125Amahi on VirtualBox2010-10-25T19:07:54Z<p>Dforbes: </p>
<hr />
<div>= Why do this? =<br />
<br />
If you want to test Amahi without upsetting your existing network configuration, one of the easiest ways of doing so is using a virtual machine. The following description applies to VirtualBox, version 3.2.10. It results in a functioning Amahi install that can be accessed both from the host machine and other VMs, including PXE-booting VM.<br />
<br />
= Prerequisites =<br />
<br />
* A working installation of VirtualBox<br />
* An express CD image (this was tested with Amahi-5.4-Express-2.6-Beta-i386.iso)<br />
* A desire to do this!<br />
<br />
= The catch =<br />
<br />
The process is fractionally more complex than a standard Amahi install, because we need to tweak the VM network configuration part-way through.<br />
<br />
You will also need to know the IP address range that your version of VirtualBox uses for its "Host only" network type. Check the network configuration of the host system on Mac OS (and I expect Linux) there's an interface called "vboxnet0". At the time of writing, the default on Mac OS is 192.168.56.1.<br />
<br />
= Configure the hda =<br />
<br />
First, configure your amahi install in the usual way at the [http://www.amahi.org/user control panel]. You must use the IP address of the VirtualBox "Host only" interface as your gateway (in my case, 192.168.56.1). If you have already have Amahi on your network, you might wish to consider changing the home domain to something other than home.com.<br />
<br />
Make a note of the install code indicated.<br />
<br />
= Create the VM =<br />
Create a fresh VM in the usual VirtualBox way:<br />
<br />
* Name it as you see fit ("Amahi-test")<br />
* Select "Linux" and "Fedora" as the OS and version<br />
* Create a virtual disk for the installation: 8GB, dynamically sized should be sufficient<br />
<br />
Once you've created the VM, go to the settings window and do the following:<br />
<br />
* Check that the first network interface is configured as NAT<br />
* Under storage, attach the Express CD image as a CD<br />
<br />
= Run the installation =<br />
Start your VM and it will boot from the CD image. Work through the installer in the usual way, entering the install code that the amahi control panel gave created earlier. You may be asked to reboot a couple of times during the process. (Note that if you get the initial CD install menu back, you need to disconnect the ISO image and then reboot again.)<br />
<br />
Eventually, the console should show a text login prompt. At which point you should shut down the VM (either by sending the shutdown signal from VirtualBox or log in and issue the command).<br />
<br />
= Altering the VM network config =<br />
At this stage we are going to configure ''two'' network interfaces. Open the VirtualBox network settings window for your VM. Configure the first two adapters thus:<br />
<br />
* Adapter 1: Enabled, Attached to: Host-only Adapter, Name: vboxnet0<br />
* Adapter 2: Enabled, Attached to: NAT<br />
<br />
= Reconfiguring the system =<br />
Boot the VM and wait for the login prompt. Login as admin (default password: admin) and use su to become root. Using your favourite editor, create the file:<br />
<br />
<blockquote><pre>/etc/sysconfig/network-scripts/ifcfg-eth1</pre></blockquote><br />
<br />
with the contents:<br />
<br />
<blockquote><br />
<pre><br />
DEVICE=eth1<br />
BOOTPROTO=dhcp <br />
ONBOOT=yes<br />
</pre><br />
</blockquote><br />
<br />
Now we need to reconfigure the hda to ensure that it picks up the new network config, using the command hda-change-gw and the IP address of the host-only network. In my case:<br />
<br />
<blockquote><br />
<pre><br />
hda-change-gw 192.168.56.1<br />
</pre><br />
</blockquote><br />
<br />
Now reboot.<br />
<br />
= Test it =<br />
Wait until the VM comes back up and open a web browser. Browse to http://192.168.56.1/ should put up the usual Amahi log-in page. If not, something's gone wrong. You can also connect via ssh from the host if you don't want to use the VirtualBox console. <br />
<br />
Note that the DNS & DHCP will not be visible from the host system unless you alter the host system config. However, other VMs connected to the same host-only network will be able to use these services, including PXE-booting.<br />
<br />
= Other approaches to network config =<br />
Amahi will work behind VirtualBox NAT quite happily, but at the time of writing, VirtualBox port-forwarding doesn't play nicely with Amahi's network config. (Or at least it didn't for me.) You also can't have two virtual machines talking to each other for the purposes of testing PXE-booting.<br />
<br />
If you want Amahi within the VM to serve other machines on your LAN, select bridged mode instead of NAT initially and don't alter the network config. (The basic install process will ''just work''.)</div>Dforbeshttps://wiki.amahi.org/index.php?title=Amahi_on_a_VM&diff=20119Amahi on a VM2010-10-25T19:02:08Z<p>Dforbes: </p>
<hr />
<div>Installing Amahi on a Virtual Machine (VM) is not too different than installing on real hardware. Many people have done it with [[VirtualBox]], [[VMware]] Server, [[VMware]] Fusion and [[VMware]] Workstation.<br />
<br />
The only real difference is in finding out what the network settings are, because we recommend you run the VM in NAT mode if you are testing things out, i.e. unless you plan to use the VM to serve other systems.<br />
<br />
= Install Fedora and Find the Network Settings =<br />
<br />
* Install fedora first, in NAT mode preferably, so that you have the same network settings.<br />
* Find out the settings inside your VM, then program them in a profile for this HDA in http://www.amahi.org. To do this use:<br />
# ifconfig to see your network address<br />
# route -n to see your gateways' address<br />
<br />
= Installing Amahi on VirtualBox =<br />
<br />
See [[Amahi_on_VirtualBox]] for detailed instructions on configuring the VM and installing Amahi within it.</div>Dforbeshttps://wiki.amahi.org/index.php?title=Amahi_on_VirtualBox&diff=20113Amahi on VirtualBox2010-10-25T18:54:28Z<p>Dforbes: </p>
<hr />
<div>= Why do this? =<br />
<br />
If you want to test Amahi without upsetting your existing network configuration, one of the easiest ways of doing so is using a virtual machine. The following description applies to VirtualBox, version 3.2.10. It results in a functioning Amahi install that can be accessed both from the host machine and other VMs, including PXE-booting VM.<br />
<br />
= Prerequisites =<br />
<br />
* A working installation of VirtualBox<br />
* An express CD image (this was tested with Amahi-5.4-Express-2.6-Beta-i386.iso)<br />
* A desire to do this!<br />
<br />
= The catch =<br />
<br />
The process is fractionally more complex than a standard Amahi install, because we need to tweak the VM network configuration part-way through.<br />
<br />
You will also need to know the IP address range that your version of VirtualBox uses for its "Host only" network type. Check the network configuration of the host system on Mac OS (and I expect Linux) there's an interface called "vboxnet0". At the time of writing, the default on Mac OS is 192.168.56.1.<br />
<br />
= Configure the hda =<br />
<br />
First, configure your amahi install in the usual way at the [http://www.amahi.org/user control panel]. You must use the IP address of the VirtualBox "Host only" interface as your gateway (in my case, 192.168.56.1). If you have already have Amahi on your network, you might wish to consider changing the home domain to something other than home.com.<br />
<br />
Make a note of the install code indicated.<br />
<br />
= Create the VM =<br />
Create a fresh VM in the usual VirtualBox way:<br />
<br />
* Name it as you see fit ("Amahi-test")<br />
* Select "Linux" and "Fedora" as the OS and version<br />
* Create a virtual disk for the installation: 8GB, dynamically sized should be sufficient<br />
<br />
Once you've created the VM, go to the settings window and do the following:<br />
<br />
* Check that the first network interface is configured as NAT<br />
* Under storage, attach the Express CD image as a CD<br />
<br />
= Run the installation =<br />
Start your VM and it will boot from the CD image. Work through the installer in the usual way, entering the install code that the amahi control panel gave created earlier. You may be asked to reboot a couple of times during the process. (Note that if you get the initial CD install menu back, you need to disconnect the ISO image and then reboot again.)<br />
<br />
Eventually, the console should show a text login prompt. At which point you should shut down the VM (either by sending the shutdown signal from VirtualBox or log in and issue the command).<br />
<br />
= Altering the VM network config =<br />
At this stage we are going to configure ''two'' network interfaces. Open the VirtualBox network settings window for your VM. Configure the first two adapters thus:<br />
<br />
* Adapter 1: Enabled, Attached to: Host-only Adapter, Name: vboxnet0<br />
* Adapter 2: Enabled, Attached to: NAT<br />
<br />
= Reconfiguring the system =<br />
Boot the VM and wait for the login prompt. Login as admin (default password: admin) and use su to become root. Using your favourite editor, create the file:<br />
<br />
<blockquote><pre>/etc/sysconfig/network-scripts/ifcfg-eth1</pre></blockquote><br />
<br />
with the contents:<br />
<br />
<blockquote><br />
<pre><br />
DEVICE=eth1<br />
BOOTPROTO=dhcp <br />
ONBOOT=yes<br />
</pre><br />
</blockquote><br />
<br />
Now we need to reconfigure the hda to ensure that it picks up the new network config, using the command hda-change-gw and the IP address of the host-only network. In my case:<br />
<br />
<blockquote><br />
<pre><br />
hda-change-gw 192.168.56.1<br />
</pre><br />
</blockquote><br />
<br />
Now reboot.<br />
<br />
= Test it =<br />
Wait until the VM comes back up and open a web browser. Browse to http://192.168.56.1/ should put up the usual Amahi log-in page. If not, something's gone wrong. You can also connect via ssh from the host if you don't want to use the VirtualBox console. <br />
<br />
Note that the DNS & DHCP will not be visible from the host system unless you alter the host system config. However, other VMs connected to the same host-only network will be able to use these services, including PXE-booting.</div>Dforbeshttps://wiki.amahi.org/index.php?title=Amahi_on_VirtualBox&diff=20107Amahi on VirtualBox2010-10-25T18:48:30Z<p>Dforbes: </p>
<hr />
<div>= Why do this? =<br />
<br />
If you want to test Amahi without upsetting your existing network configuration, one of the easiest ways of doing so is using a virtual machine. The following description applies to VirtualBox, version 3.2.10. It results in a functioning Amahi install that can be accessed both from the host machine and other VMs, including PXE-booting VM.<br />
<br />
= Prerequisites =<br />
<br />
* A working installation of VirtualBox<br />
* An express CD image (this was tested with Amahi-5.4-Express-2.6-Beta-i386.iso)<br />
* A desire to do this!<br />
<br />
= The catch =<br />
<br />
The process is fractionally more complex than a standard Amahi install, because we need to tweak the VM network configuration part-way through.<br />
<br />
You will also need to know the IP address range that your version of VirtualBox uses for its "Host only" network type. Check the network configuration of the host system on Mac OS (and I expect Linux) there's an interface called "vboxnet0". At the time of writing, the default on Mac OS is 192.168.56.1.<br />
<br />
= Configure the hda =<br />
<br />
First, configure your amahi install in the usual way at the [http://www.amahi.org/user control panel]. You must use the IP address of the VirtualBox "Host only" interface as your gateway (in my case, 192.168.56.1). If you have already have Amahi on your network, you might wish to consider changing the home domain to something other than home.com.<br />
<br />
Make a note of the install code indicated.<br />
<br />
= Create the VM =<br />
Create a fresh VM in the usual VirtualBox way:<br />
<br />
* Name it as you see fit ("Amahi-test")<br />
* Select "Linux" and "Fedora" as the OS and version<br />
* Create a virtual disk for the installation: 8GB, dynamically sized should be sufficient<br />
<br />
Once you've created the VM, go to the settings window and do the following:<br />
<br />
* Check that the first network interface is configured as NAT<br />
* Under storage, attach the Express CD image as a CD<br />
<br />
= Run the installation =<br />
Start your VM and it will boot from the CD image. Work through the installer in the usual way, entering the install code that the amahi control panel gave created earlier. You may be asked to reboot a couple of times during the process. (Note that if you get the initial CD install menu back, you need to disconnect the ISO image and then reboot again.)<br />
<br />
Eventually, the console should show a text login prompt. At which point you should shut down the VM (either by sending the shutdown signal from VirtualBox or log in and issue the command).<br />
<br />
= Altering the VM network config =<br />
Read this piece carefully as we are going to configure *two* network interfaces. Open the VirtualBox network settings window for your VM. Configure the first two adapters thus:<br />
<br />
* Adapter 1: Enabled, Attached to: Host-only Adapter, Name: vboxnet0<br />
* Adapter 2: Enabled, Attached to: NAT<br />
<br />
= Reconfiguring the system =<br />
Boot the VM and wait for the login prompt. Login as admin (default password: admin) and use su to become root. Using your favourite editor, create the file:<br />
<br />
/etc/sysconfig/network-scripts/ifcfg-eth1<br />
<br />
with the contents:<br />
<br />
DEVICE=eth1<br />
BOOTPROTO=dhcp<br />
ONBOOT=yes<br />
<br />
Now we need to reconfigure the hda to ensure that it picks up the new network config, using the command hda-change-gw and the IP address of the host-only network. In my case:<br />
<br />
hda-change-gw 192.168.56.1<br />
<br />
Now reboot.<br />
<br />
= Test it =<br />
Wait until the VM comes back up and open a web browser. Browse to http://192.168.56.1/ should put up the usual Amahi log-in page. If not, something's gone wrong. You can also connect via ssh from the host if you don't want to use the VirtualBox console. <br />
<br />
Note that the DNS & DHCP will not be visible from the host system unless you alter the host system config. However, other VMs connected to the same host-only network will be able to use these services, including PXE-booting.</div>Dforbeshttps://wiki.amahi.org/index.php?title=Amahi_on_VirtualBox&diff=20101Amahi on VirtualBox2010-10-25T18:39:56Z<p>Dforbes: Created page with '= Why do this? = If you want to test Amahi without upsetting your existing network configuration, one of the easiest ways of doing so is using a virtual machine. The following …'</p>
<hr />
<div>= Why do this? =<br />
<br />
If you want to test Amahi without upsetting your existing network configuration, one of the easiest ways of doing so is using a virtual machine. The following description applies to VirtualBox, version 3.2.10. It results in a functioning Amahi install that can be accessed both from the host machine and other VMs, including PXE-booting VM.<br />
<br />
= Prerequisites =<br />
<br />
* A working installation of VirtualBox<br />
* An express CD image (this was tested with Amahi-5.4-Express-2.6-Beta-i386.iso)<br />
* A desire to do this!<br />
<br />
= The catch =<br />
<br />
The process is fractionally more complex than a standard Amahi install, because we need to tweak the VM network configuration part-way through.<br />
<br />
You will also need to know the IP address range that your version of VirtualBox uses for its "Host only" network type. Check the network configuration of the host system on Mac OS (and I expect Linux) there's an interface called "vboxnet0". At the time of writing, the default on Mac OS is 192.168.56.1.<br />
<br />
= Configure the hda =<br />
<br />
First, configure your amahi install in the usual way at the [http://www.amahi.org/user control panel]. You must use the IP address of the VirtualBox "Host only" interface as your gateway. Make a note of the install code indicated.<br />
<br />
= Create the VM =<br />
Create a fresh VM in the usual VirtualBox way:<br />
<br />
* Name it as you see fit ("Amahi-test")<br />
* Select "Linux" and "Fedora" as the OS and version<br />
* Create a virtual disk for the installation: 8GB, dynamically sized should be sufficient<br />
<br />
Once you've created the VM, go to the settings window and do the following:<br />
<br />
* Check that the first network interface is configured as NAT<br />
* Under storage, attach the Express CD image as a CD<br />
<br />
= Run the installation =<br />
Start your VM and it will boot from the CD image. Work through the installer in the usual way, entering the install code that the amahi control panel gave created earlier. You may be asked to reboot a couple of times during the process. (Note that if you get the initial CD install menu back, you need to disconnect the ISO image and then reboot again.)<br />
<br />
Eventually, the console should show a text login prompt. At which point you should shut down the VM (either by sending the shutdown signal from VirtualBox or log in and issue the command).<br />
<br />
= Altering the VM network config =<br />
Read this piece carefully as we are going to configure *two* network interfaces. Open the VirtualBox network settings window for your VM. Configure the first two adapters thus:<br />
<br />
* Adapter 1: Enabled, Attached to: Host-only Adapter, Name: vboxnet0<br />
* Adapter 2: Enabled, Attached to: NAT<br />
<br />
= Reconfiguring the system =<br />
Boot the VM and wait for the login prompt. Login as admin (default password: admin) and use su to become root. Using your favourite editor, create the file:<br />
<br />
/etc/sysconfig/network-scripts/ifcfg-eth1<br />
<br />
with the contents:<br />
<br />
DEVICE=eth1<br />
BOOTPROTO=dhcp<br />
ONBOOT=yes<br />
<br />
Now execute (still as root):</div>Dforbes