How to bootstrap a Synology DS212+

This guide explains how to bootstrap your Synology 212+ NAS. If you have a different NAS, please check this wiki entry for the cpu type and this list for the bootstrap file.

Note: There seems to be an easier alternative on this page: http://packages.quadrat4.de/ Basically you just need to add the repository and install the “Bootstrap Installer”.

Bootstrap

  • Control Panel > Terminal > Enable SSH Service
  • SSH into your NAS, login as root and use the password from the admin account.
  • Download the bootstrap package for your NAS (look here)
    wget http://wizjos.endofinternet.net/synology/archief/syno-mvkw-bootstrap_1.2-7_arm-ds111.xsh
    
  • Change the file permissions
    chmod +x syno-mvkw-bootstrap_1.2-7_arm-ds111.xsh
    
  • Run the file
    sh syno-mvkw-bootstrap_1.2-7_arm-ds111.xsh
    
  • Remove the file
    rm syno-mvkw-bootstrap_1.2-7_arm-ds111.xsh
    
  • Edit your **.profile** ONLY FOR DSM 4.0 Comment the lines following lines in the file /root/.profile PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/syno/sbin:/usr/syno/bin:/usr/local/sbin:/usr/local/bin export PATH
  • Apply this fix: MissleHugger DSM 4.0/4.1 IPKG fix
  • reboot the server
    reboot
    
  • Login again and update your repo
    ipkg update
    
  • Done!

Additional steps

Enable a user account for SSH

  • Install nano (optional)
    ipkg install nano
    
  • Edit the passwd file
    nano /etc/passwd
    

change

myusername:x:1026:100:MyName:/var/services/homes/myusername:/sbin/nologin

to

myusername:x:1026:100:MyName:/var/services/homes/myusername:/bin/ash

Disable the root account and install sudo

  • Install the sudo package
    ipkg install sudo
    
  • Edit the sudoers file
    nano /opt/etc/sudoers
    
  • Add this entry (replace it with your username)
    myusername ALL=(ALL) ALL
    
  • Disable root login
    nano /etc/ssh/sshd_config
    
  • Add this line
    PermitRootLogin no
    
  • Save the file and reboot the server (or restart the SSH deamon)

Install screen

  • Install the screen package
    ipkg install screen