{"id":228,"date":"2012-09-25T23:52:52","date_gmt":"2012-09-25T23:52:52","guid":{"rendered":"https:\/\/shan.info\/new\/running-your-own-application-at-startup\/"},"modified":"2012-09-25T23:52:52","modified_gmt":"2012-09-25T23:52:52","slug":"running-your-own-application-at-startup","status":"publish","type":"post","link":"https:\/\/shan.info\/new\/running-your-own-application-at-startup\/","title":{"rendered":"Running Your Own Application at Startup"},"content":{"rendered":"<h3 style=\"color: #000000; background-image: none; margin-bottom: 1.3em; padding-top: 25px; border-bottom-style: none; font-size: 17px; font-family: sans-serif; line-height: 19px;\"><span class=\"mw-headline\" id=\"Method_1\">Method 1<\/span><\/h3>\n<ol style=\"line-height: 19px; margin: 0.3em 0px 0px 3.2em; padding: 0px; list-style-image: none; font-family: sans-serif; font-size: 13px;\">\n<li style=\"margin-bottom: 0.1em;\">Log into your QNAP device using SSH or Telnet, for instance by using Putty<\/li>\n<li style=\"margin-bottom: 0.1em;\">Optional: install nano; use&nbsp;<b>ipkg install nano<\/b>&nbsp;&amp; edit with nano instead of vi<\/li>\n<li style=\"margin-bottom: 0.1em;\">TS-201: Mount the config ramblock \/dev\/mtdblock4:\n<pre style=\"padding: 1em 1em 25px; border: 1px dashed #2f6fab; background-color: #eeeeee; line-height: 1.1em; width: 500px;\"># mount -t ext2 \/dev\/mtdblock4 \/tmp\/config <\/pre>\n<\/li>\n<li style=\"margin-bottom: 0.1em;\">TS-109, TS-109P, TS-110, TS-119, TS-209, TS-209P, TS-219, TS-409 (Marvell ARM), TS-419P: Mount the config ramblock \/dev\/mtdblock5:\n<pre style=\"padding: 1em 1em 25px; border: 1px dashed #2f6fab; background-color: #eeeeee; line-height: 1.1em; width: 500px;\"># mount -t ext2 \/dev\/mtdblock5 \/tmp\/config<\/pre>\n<\/li>\n<li style=\"margin-bottom: 0.1em;\">TS-439, TS-509, TS-639, TS-809, TS-809U (x86): Mount the config ramblock \/dev\/sdx6:\n<pre style=\"padding: 1em 1em 25px; border: 1px dashed #2f6fab; background-color: #eeeeee; line-height: 1.1em; width: 500px;\"># mount -t ext2 \/dev\/sdx6 \/tmp\/config<\/pre>\n<\/li>\n<li style=\"margin-bottom: 0.1em;\">Create\/Edit \/tmp\/config\/autorun.sh .\n<ol style=\"line-height: 1.5em; margin: 0.3em 0px 0px 3.2em; padding: 0px; list-style-image: none;\">\n<li style=\"margin-bottom: 0.1em;\">either using vi:\n<pre style=\"padding: 1em 1em 25px; border: 1px dashed #2f6fab; background-color: #eeeeee; line-height: 1.1em; width: 400px;\"># vi \/tmp\/config\/autorun.sh<\/pre>\n<ol style=\"line-height: 1.5em; margin: 0.3em 0px 0px 3.2em; padding: 0px; list-style-image: none;\">\n<li style=\"margin-bottom: 0.1em;\">Get vi editor into edit mode:&nbsp;<b>press a<\/b><\/li>\n<li style=\"margin-bottom: 0.1em;\">Edit whatever you need to<\/li>\n<li style=\"margin-bottom: 0.1em;\">Exit edit mode:&nbsp;<b>press ESC<\/b><\/li>\n<li style=\"margin-bottom: 0.1em;\">Save and exit:&nbsp;<b>press ZZ<\/b><\/li>\n<\/ol>\n<\/li>\n<li style=\"margin-bottom: 0.1em;\">or editing it using a desktop PC and e.g. SFTP<\/li>\n<\/ol>\n<\/li>\n<li style=\"margin-bottom: 0.1em;\">Ensure that \/tmp\/config\/autorun.sh is executable:\n<pre style=\"padding: 1em 1em 25px; border: 1px dashed #2f6fab; background-color: #eeeeee; line-height: 1.1em; width: 500px;\"># chmod +x \/tmp\/config\/autorun.sh<\/pre>\n<\/li>\n<li style=\"margin-bottom: 0.1em;\"><b>IMPORTANT:<\/b>&nbsp;Unmount the mounted flash partition:\n<pre style=\"padding: 1em 1em 25px; border: 1px dashed #2f6fab; background-color: #eeeeee; line-height: 1.1em; width: 500px;\"># umount \/tmp\/config<\/pre>\n<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>Method 1 Log into your QNAP device using SSH or Telnet, for instance by using Putty Optional: install nano; use&nbsp;ipkg install nano&nbsp;&amp; edit with nano instead of vi TS-201: Mount the config ramblock \/dev\/mtdblock4: # mount -t ext2 \/dev\/mtdblock4 \/tmp\/config TS-109, TS-109P, TS-110, TS-119, TS-209, TS-209P, TS-219, TS-409 (Marvell ARM), TS-419P: Mount the config ramblock [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[50],"tags":[],"class_list":["post-228","post","type-post","status-publish","format-standard","hentry","category-qnap"],"_links":{"self":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/posts\/228","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/comments?post=228"}],"version-history":[{"count":0,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/posts\/228\/revisions"}],"wp:attachment":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/media?parent=228"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/categories?post=228"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/tags?post=228"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}