NAS

2017

Letsencypt Certs

  • Must have port 80 open through to the Synology NAS - the renewal script needs to host a key/cert during the re-registration process.
  • can force renewal with /usr/syno/sbin/syno-letsencrypt renew-all

2014

Synology/ParentialControl

Bootstrap

Just to be a PITA, it appeats most DSM updates will remove the bootstrap.

Instructions http://forum.synology.com/wiki/index.php/Overview_on_modifying_the_Synology_Server,_bootstrap,_ipkg_etc

Copy the bootstrap script to the NAS Login as root

SNAZZY> chmod +x syno-e500-bootstrap_1.2-7_powerpc.xsh
SNAZZY> sh syno-e500-bootstrap_1.2-7_powerpc.xsh

If the following message pops up - you need to do what is say otherwise the bootstrapping wont work :(

Backup your configuration settings, then type:
  rm -rf /volume1/@optware
  rm -rf /usr/lib/ipkg
This will remove all existing optware packages.

Modify the root .profile to include $PATH

vi /roo/.profile
PATH=$PATH:/sbin:/bin:/usr/sbin:/usr/bin:/usr/syno/sbin:/usr/syno/bin:/usr/local/sbin:/usr/local/bin
export PATH

Restart

init 6

Add ipkg install sudo ipkg install less ipkg install rrdtool

Edit crontab /etc/crontab

earlier

Best decision I have made in a long time, this little unit (DS213+) is a cracker.

Just upgraded to DSM 5.0

DS213+ --> Freescale P1022 For Freescale PowerPC QorIQ P1022 - Please use the same boostrap as for 8543 and 8553 PPC CPUs. Since they are all e500 CPUs, they share the same compiled binaries.

Need to re-run the bootstrap - I had to uninstall then re-install, same with the config file editor.

Following instructions from: http://forum.synology.com/wiki/index.php/Overview_on_modifying_the_Synology_Server,_bootstrap,_ipkg_etc

as root wget http://ipkg.nslu2-linux.org/feeds/optware/syno-e500/cross/unstable/syno-e500-bootstrap_1.2-7_powerpc.xsh chmod +x syno-e500-bootstrap_1.2-7_powerpc.xsh sh syno-e500-bootstrap_1.2-7_powerpc.xsh

have ipkg in /volume1/@optware/share/ipkg possibly run with sh??

Previously this worked (prior to installting DSM 5.0)

http://packages.quadrat4.de/

Photo Station 6

Cool application that allows users to create folders under the default /photo share. (remember to make all albumns private). Problem is that if you have other photo shares (say syncing peoples my photos folders to their own shared folder on the NAS), their photos wont be included.

One solution is to add a symbolic link - you wont see the files in file station, however photo station will index them :)

ssh NAS
cd /volume1/photo
ln -s /volume1/user_share/ user_photos

Cloud Station

Pros

  • Can sync via a http proxy
  • Can have multiple users syncing the same files
  • Easier to configure (with client) than rsync
  • can be run constantly (default) or launch to backup

Cons

  • To make it easy to manage - need a Synology shared folder per PC directory to sync (aka PC1-userx-my documents --> NAS\userx_my_documents)
  • Copies the entire files each time its updated (dropbox will do delta files
  • Runs constantly, thus if MS Word auto saves the file every 10 minutes, thats 6 updates an hour.

2012 Synology NAS solution

Since the hardware which my media centre is running keeps falling over (has done randomly for the past 7 years -sometimes its a month sometimes its up for 10 minutes) I'm looking at getting a Synology NAS device as it will do almost everything I want out of the box.

  • Add sftp / ssh support - this can now be done from the menu. To change the SSH ports (or to allow multiple like 22 and 1022) edit /etc/ssh/sshd_config and add multiple Port lines, you will need to rebook the diskstation for the config to apply.
Port 22
Port 1022
  • Chown files so admin can sudo - to become root
  • crontab - having issues with the crontab entries being ignored post reboot. Apparently only those jobs running as root will be kept. thus this entry should work
#minute hour    mday    month   wday    who     command
0       14      *       *       2,5     root    /usr/syno/bin/synopkg chkupgradepkg
*/5     *       *       *       *       root    su - cacti -c "sudo /opt/bin/php /volume1/web/cacti/poller.php > /dev/null 2>&1"

Changed the executable path in 2014 -->

*/5     *       *       *       *       root    su - cacti -c "sudo /usr/bin/php /volume1/web/cacti/poller.php > /dev/null 2>&1"
  • DNS and DHCP - resolve only netflix.com via unblock-us.com DNS

    • install the synology DHCP client.
    • add ISP's DNS's to /etc/resolv.conf,
    • add the following to /etc/dhcpd/dhcpd-eth0-eth00.conf
server=/netflix.com/192.168.1.1

Remember to go stop and start the dhcp service after doing this

** Configure modem (at 192.168.1.1) to use unblock-us.com's primary and secondary DNS (synology's dnsmasq cant have the same domain name mapping as a 'server' option in the config, thus this will get around this as the NAS will use the ISP's DNS's for all other queries directly.

unblock-us services supported http://support.unblock-us.com/customer/portal/articles/291570

I have recently purchased a Synology Diskstation DS213+ and to date (still installing it) its doing most things I want it too.

Poller crontab

*/5     *       *       *       *       cacti   /opt/bin/php /volume1/web/cacti/poller.php > /dev/null 2>&1

Netflix in NZ

111.118.175.56
118.127.33.48
  • May also be able to use tunlr.ne DNS's for free (and their proxy service I Assume
184.82.222.5
199.167.30.144

another option is to setup a VPS in the US and then VPN to it http://www.lowendspirit.com/locations.html

Next step is to only us unblock-us.com DNS settings when were accessing NetFlix

the inbuilt DHCP application is built on dnsmasq... thus information below is possible. http://www.thekelleys.org.uk/dnsmasq/doc.html

from http://forums.smallnetbuilder.com/showthread.php?t=8266

You need ad the options to dnsmasq.conf and restart dnsmasq. To do this automatically at every boot you can use the services-start script:

1. Enabele jffs in the router webui and restart. 2. ssh to the router and mkdir /jffs/scripts/ 3. vi /jffs/scripts/services-start and paste:

#!/bin/sh echo "server=/netflix.com/111.118.175.56" >> /tmp/etc/dnsmasq.conf echo "server=/netflix.com/118.127.33.48" >> /tmp/etc/dnsmasq.conf killall dnsmasq dnsmasq -c 1500 --log-async -n

4. save and chmod +x /jffs/scripts/services-start 5. restart router

Squid

http://www.ingmarverheij.com/configuring-proxy-server-on-a-synology-nas/

Proxy autoconfig

Enable mime-types by adding

/usr/syno/apache/conf/mime.types

# MIME type (lowercased)                        Extensions
# ============================================  ==========
# Neil 2013
application/x-ns-proxy-autoconfig               pac
application/x-ns-proxy-autoconfig               dat

alternative to netflixs (but you get netflixs content??

http://www.playon.tv/

Toolbox
Favorite Categories