Raptor2k Posted November 10, 2019 Share Posted November 10, 2019 Hello community, i am a litte ashamed but i can not find the bash command for starting my array. I want to start my array using my go config file: sleep 1 wget --user=xxx --password='xxx' ftp://xxx -O /root/xxx sleep 4 7z e /root/keyfile.7z -pxxx -O/root/ sleep 10 -> Command bash for starting array ??? <- The command should have the same function as the button inside the GUI / Main Page -> Button " Start Array". Thank for your help and mabye you can show me the manuel / webpage where i can find the bash commands for unraid. Kind regadrs and thx for your help Raptor2k Quote Link to comment
Squid Posted November 10, 2019 Share Posted November 10, 2019 13 minutes ago, Raptor2k said: I want to start my array using my go config file: Admittedly I'm confused. Why would you want to start the array via a command in the "go" file instead of simply going to Settings - Disk Settings - and enabling auto start? Quote Link to comment
Raptor2k Posted November 11, 2019 Author Share Posted November 11, 2019 On 11/10/2019 at 4:48 PM, Squid said: Admittedly I'm confused. Why would you want to start the array via a command in the "go" file instead of simply going to Settings - Disk Settings - and enabling auto start? i want an extra command cause my array is not auto starting. My Unraid Nas is downloading the file, unzip it but not start the array. Auto Start is enabled. So i thought... add an extra line of code in the go file. Thx for your fast respone. Quote Link to comment
Squid Posted November 11, 2019 Share Posted November 11, 2019 Here's the starting point for a command. But, you'd also need to append the current csrf token (/var/local/emhttp/var.ini). But even there, I have no idea if the command would work under 6.8 since you're not logged in either. My best suggestion would be to place those commands for the download in the go file, prior to the emhttp line (with appropriate waits to ensure the network is running) https://forums.unraid.net/topic/50490-solved-commands-to-start-and-stop-array/?tab=comments#comment-496967 Quote Link to comment
bonienl Posted November 11, 2019 Share Posted November 11, 2019 /usr/local/sbin/emhttp Is used to start the array and other relevant services. Make this the last command in your go file Quote Link to comment
Raptor2k Posted November 14, 2019 Author Share Posted November 14, 2019 Thank you Squid and bonienl. The hint of boninl works flawlessly. Here is my new go config file for the community: #!/bin/bash # Start the Management Utility sleep 1 wget --user=xxx --password='xxx' ftp://xxx.7z -O /root/xxx.7z sleep 4 7z e /root/xxx.7z -pxxx -O/root/ sleep 4 /usr/local/sbin/emhttp & Now the services start and unraid can unlock my array. Just for the record. I am using version 6.7.2 Kind regards Raptor2k Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.