Turning your My Book Live Duo into a DHCP server

I use my My Book on a closed network at home with no DHCP Server running on it, and decided I was sick of assigning a static ip address on my laptop everytime I connected.

So I resolved to try and install a DHCP server on my my book, and will post the process below for anyone else who is interested.

If anyone wants the full word document with pictures (don’t want to put in pictures here), reply and I will find somewhere to upload it to and then post a link, however I won’t bother uploading if no-one is interested.

Enabling SSH
Before we can begin, you will need to enable SSH access to your My Book Live Duo.
1.    Open up a web browser and type in the address of your mybook in the address bar up top.

2.    Enter the password for the device if prompted to.

3.    Edit the address bar so that the path is shown as “/UI/ssh” and then tick the Enable box next to ‘SSH Access’

Ensuring your My Book has internet access
In order to update and download the updates for your My Book Live Duo, you will need internet access.  This is accomplished by entering the default gateway IP address for your network – the router which supplies internet, or the computer which is sharing their internet across your network.
1.    Log into the web browser for your My Book, and go to the Settings → Network tab.
2.    Your My Book will do a quick test to check internet connectivity and display ‘Good’ next to ‘Internet Access’ if it passes like below.

You will need to enter the IP Address, Netmask, Gateway, and at least one of the DNS Server entries.  Your DNS Server entries will differ from mine, and you should be able to see what settings you will need for this and the gateway if you open up a command prompt on any machine which has internet access on your network by pressing the ‘Windows Key’ + ‘R’, and then typing ‘cmd’.

Once the command line has opened, type “ipconfig /all”.

Gaining Console Access via PuTTY
If you don’t already have PuTTY, download it from the.earth.li/~sgtatham/putty/0.62/x86/putty.exe
1.    Now that SSH is enabled, open up PuTTY and select SSH using the default port of 22. Replace the IP address in the picture below with the IP address of your My Book Live, and click open when done.

 2.    When prompted for a username and password, the factory defaults are “root” as the username, with “welc0me” for the password.

Updating OS and downloading required packages
Now you will need to update the OS and download additional packages required to support running your My Book as a DHCP Server.
1.    Ensure that the “/shares/Public/build” folder exists, creating it if necessary using the ‘mkdir’ command.

2.    Next, edit the “/etc/apt/sources.list” file using nano to make sure the web addresses are pointing to " http://ftp.us.debian.org/debian".

3.    After this is checked, we can finally update your My Book with the command “apt-get update”.
This will download all the additional packages, among which are included the ones we need to setup the My Book Live Duo as a DHCP server.

Installing DHCP-Server
1.    Type “apt-get install dhcp3-server”, Accept the warnings, and the DHCP-Server will be installed.

If you get some fails near the end of this, do not be alarmed as it simply fails to start since it hasn’t been configured yet.
2.    Navigate to “/etc/dhcp/” and make a copy of the ‘dhcpd.conf’ file so you have something to revert to if you make a mistake.

3.    Edit ‘dhcpd.conf’ using a text editor like nano.

4.    Ensure the following lines are uncommented and reflect the network setup you would like;
option domain-name “test1.com”;
option domain-name-servers 192.0.0.1, 194.2.0.50;
default-lease-time 3600;
subnet 192.0.0.0 netmask 255.255.255.0 {
range 192.0.0.200 192.0.0.254;
option routers 192.0.0.151;
}

5.    Edit the file “/etc/default/isc-dhcp-server”, and set the interface which will run the DHCP Server by changing the line INTERFACES=”” to INTERFACES=”eth0”.
 eth0 is simply the first Ethernet port, and most My Book Live’s only have the one Ethernet port.

6.    After you’ve made the changes, restart the rsyslog and isc-dhcp-server services with the following commands;
invoke-rc.d rsyslog restart
invoke-rc.d isc-dhcp-server restart

If you get errors here and it states that your configuration file is incorrect, go back to “/etc/dhcp/dhcpd.conf “ and re-check for mistakes.
If the isc-dhcp-server failes to stop, however it sucessfully starts, that is ok.

Your My Book Live should now be giving out DHCP addresses to clients who request a lease.

Sources:

http://www.debianhelp.co.uk/dhcp.htm
http://www.goletdoit.com/how-to-setup-dhcp-server-on-debian/
http://support.wdc.com/product/download.asp?groupid=903&sid=164&lang=en

1 Like

Nice, thanks for sharing.

Hi NatoNZ,

Could you post the word document?  I just got the MyBookLive.  Your steps are very helpful but screenshots would be great for reference.

Thanks in advance!

Here; http://www.mediafire.com/view/?p202nvtxqwnhmci

Hope it helps.

Edit: just had a look, and some of the pictures look a bit weird when looking at it in the web-browser on mediafire, so I suggest downloading it then opening it instead.