0

Installing SQUID on a Synology NAS

I’m not going to go into exactly why (it’s a minor networking niggle following on from a change in broadband provider) but I wanted a simple HTTP proxy in my lab so that my lab VMs could get out on to the internet. Mostly for installing updates etc.

Since my NAS is ideally placed in my network I thought that I’d use that. It’s only a short-term thing anyway.

Now in order to get a proxy service on to the NAS, I needed to setup IPKG first. This allowed me to install and configure SQUID as follows:

1. Open an SSH session to the NAS

2. Download and install SQUID

[text]ipkg install squid[/text]

3. Perform a couple of configuration commands

[text]squid -k parse
squid -z
ln -s /opt/etc/init.d/S80squid /usr/syno/etc/rc.d/[/text]

4. SQUID can now be started using /opt/etc/init.d/S80squid start

Now there may be some additional changes you might want to make. By default SQUID will accept connections from a standard set of internal networks as follows:

[text]acl localnet src 10.0.0.0/8     # RFC1918 possible internal network
acl localnet src 172.16.0.0/12  # RFC1918 possible internal network
acl localnet src 192.168.0.0/16 # RFC1918 possible internal network[/text]

However, you may want to tie this down for one reason or another. For me, I’m not too bothered. Any changes can be done by editing /opt/etc/squid/squid.conf.

Want to check that it works? I configured the proxy config in my VM as follows:

CapturFiles-201409248_110961

And then monitored the proxy access file using tail:

[text]tail -f /opt/var/squid/logs/access.log
1409911439.044    141 192.168.100.151 TCP_MISS/200 405 HEAD http://download.windowsupdate.com/v9/windowsupdate/redir/muv4wuredir.cab? – DIRECT/80.239.217.24 application/octet-stream
1409911439.138     80 192.168.100.151 TCP_MISS/200 24017 GET http://download.windowsupdate.com/v9/windowsupdate/redir/muv4wuredir.cab? – DIRECT/80.239.217.24 application/octet-stream
1409911445.219     46 192.168.100.151 TCP_MISS/200 405 HEAD http://ds.download.windowsupdate.com/v11/3/windowsupdate/selfupdate/WSUS3/x64/Win7SP1/wsus3setup.cab? – DIRECT/213.120.161.243 application/octet-stream
1409911445.246     16 192.168.100.151 TCP_MISS/200 34418 GET http://ds.download.windowsupdate.com/v11/3/windowsupdate/selfupdate/WSUS3/x64/Win7SP1/wsus3setup.cab? – DIRECT/213.120.161.243 application/octet-stream[/text]

0

How to install IPKG on a Synology NAS

Sometimes you want to install “community” or third party packages on your Synology NAS and they require IPKG (Itsy Package Management System) to be present. Instruction about how to go about this seem to vary and are often specific for the CPU inside your NAS. The easiest method that I’ve found for getting IPKG installed is as follows…

First job is to open an SSH session to the NAS and confirm what type of processor it has. This can be done using the following command:

[text]cat /proc/cpuinfo | grep model[/text]

For my DS1513+ it returns:

[text]model: 54
model name: Intel(R) Atom(TM) CPU D2701   @ 2.13GHz
model: 54
model name: Intel(R) Atom(TM) CPU D2701   @ 2.13GHz
model: 54
model name: Intel(R) Atom(TM) CPU D2701   @ 2.13GHz
model: 54
model name: Intel(R) Atom(TM) CPU D2701   @ 2.13GHz[/text]

Next you need to dig around the site http://ipkg.nslu2-linux.org/feeds/optware/ to find the correct bootstrap for your architecture. In my case it’s at http://ipkg.nslu2-linux.org/feeds/optware/syno-i686/cross/unstable/syno-i686-bootstrap_1.2-7_i686.xsh.

To install it, there are a couple of steps…

1. Within your SSH session, change to a temporary location (note that you will probably need to be logged in as root to do all this)

[text]cd /tmp[/text]

2. Download the bootstrap script

[text]wget http://ipkg.nslu2-linux.org/feeds/optware/syno-i686/cross/unstable/syno-i686-bootstrap_1.2-7_i686.xsh[/text]

3. Make the file executable

[text] chmod +x syno-i686-bootstrap_1.2-7_i686.xsh[/text]

4. Run the script

[text]sh syno-i686-bootstrap_1.2-7_i686.xsh[/text]

5. If it all went well, remove the script

[text]rm syno-i686-bootstrap_1.2-7_i686.xsh[/text]

6. Update the package list

[text]ipkg update[/text]

Well done, you’re now ready to install custom packages via ipkg.

0

LonVMUG 23rd January 2014

First VMUG of the year*. That has a nice sound to it. Full of promises for lots of good events to come.

The lovely folks who organise the London VMUG look to be putting on a super first event for 2014 and I’m looking forward to it. As well as having a distinctly “cloudy” flavour to it, there’s a series of lightning talks on home labs scheduled. I know that the committee have been debating a trial of this format for a while now because I’ve suggested it a time or two myself. It works very well at CloudCamp (which, coincidentally, is on the same day but starting at 6:30pm – register for it here if you’re interested) and I hope it will fit in very nicely here too.

Track A Track B
0830 – 0945 Event Reception
1000 – 1015 Welcome
1015 – 1100 Pernix Data – Frank Denneman
1100 – 1145 vCAC 6 – What’s New
(Matt Steiner, VMware)
1145 – 1215 Break
1215 – 1300 vSAN
(Justin Beck, VMware)
vCHS Overview
(Simon Greaves, Computacenter)
1300 – 1400 Lunch
1400 – 1450 10ZiG Nimble Storage
1500 – 1550 NSX with an Angle
(Peter Bury, VMware)
Home Lab Lightning Talks
Simon Gallagher
Erik Bussink
Frank Denneman
Alex Galbraith
1600 – 1650 How LEGO relocated to a new datacentre
(Enrico Laursen, LEGO)
vCAC Real World Deployment
(TBC)
1700 – 1715 Close
  vBeers @ The Pavilion End

So don’t miss it, register now to avoid disappointment!

(* – Actually it’s the 9th after Indianapolis, Spokane, Toledo, New Mexico, Iowa, Singapore, Louisville and Denver but for me it’ll be the first.)

0

New HP Proliant Microserver N40L

HP have recently updated their Proliant Microserver to sport a slightly nippier processor. As well as the 250Gb SATA drive it also now comes with 2Gb RAM as standard – although if you’re thinking of using one for a home lab Virtual Infrastructure you’d need to replace that with 2 x 4Gb sticks anyway.

HP’s ongoing cashback deal for this little gem is still running too. Before cashback they’re about £200 + VAT meaning that once you get your cheque back from HP, they work out at only £120 each. Not bad at all for a home lab and the AMD NEO N40L 1.5Ghz dual-core processor should be enough to handle a reasonable lab-like load.

ServersPlus are one of the places in the UK to pick one of these servers up. They even offer an ESXi 5 testbed bundle that includes the 8Gb RAM and an optical drive.

These little servers are great lab servers if you need something small and quiet. I have 3 of them running more or less full time at home and my wife hasn’t complained about the electricity bill… yet.