{"id":2280,"date":"2015-10-13T19:04:36","date_gmt":"2015-10-13T17:04:36","guid":{"rendered":"https:\/\/adrhc.go.ro\/wordpress\/?p=2280"},"modified":"2016-10-06T10:47:51","modified_gmt":"2016-10-06T08:47:51","slug":"ubuntu-creating-an-init-d-service","status":"publish","type":"post","link":"https:\/\/adrhc.go.ro\/blog\/ubuntu-creating-an-init-d-service\/","title":{"rendered":"Ubuntu: creating an init.d service"},"content":{"rendered":"<pre class=\"brush:bash shell;toolbar: false\">\r\n#create then put your script (e.g. nginx) into \/etc\/init.d with root as user & group\r\nsudo update-rc.d nginx defaults\t\t-> loads the script\r\nsudo update-rc.d nginx enable\t\t-> enable the script to run at system sturtup\/boot\r\nservice nginx start\t\t\t\t\t-> starts the service\r\nservice nginx status\r\nsystemctl -l status nginx\r\nservice --status-all\t\t\t\t-> shows status for all services\r\nsystemctl\t\t\t\t\t\t\t-> shows all active units\r\nsystemctl list-units --type=service\t-> shows all active services (--all to see loaded but inactive services too)\r\n\r\n# reload service's configuration:\r\nsudo systemctl reload nginx.service\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>#create then put your script (e.g. nginx) into \/etc\/init.d with root as user &#038; group sudo update-rc.d nginx defaults -> loads the script sudo update-rc.d nginx enable -> enable the script to run at system sturtup\/boot service nginx start -> [&hellip;]<\/p>\n<div class=\"link-more\"><a href=\"https:\/\/adrhc.go.ro\/blog\/ubuntu-creating-an-init-d-service\/#more-2280\" class=\"more-link\">Continue reading &#10142; <span class=\"screen-reader-text\">Ubuntu: creating an init.d service<\/span><\/a><\/div>","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8,33],"tags":[],"class_list":["post-2280","post","type-post","status-publish","format-standard","hentry","category-howto","category-ubuntu"],"_links":{"self":[{"href":"https:\/\/adrhc.go.ro\/blog\/wp-json\/wp\/v2\/posts\/2280","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/adrhc.go.ro\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/adrhc.go.ro\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/adrhc.go.ro\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/adrhc.go.ro\/blog\/wp-json\/wp\/v2\/comments?post=2280"}],"version-history":[{"count":0,"href":"https:\/\/adrhc.go.ro\/blog\/wp-json\/wp\/v2\/posts\/2280\/revisions"}],"wp:attachment":[{"href":"https:\/\/adrhc.go.ro\/blog\/wp-json\/wp\/v2\/media?parent=2280"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/adrhc.go.ro\/blog\/wp-json\/wp\/v2\/categories?post=2280"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/adrhc.go.ro\/blog\/wp-json\/wp\/v2\/tags?post=2280"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}