HBS3 commands using CLI
-
- Getting the hang of things
- Posts: 50
- Joined: Sat Nov 21, 2009 7:31 am
- Location: Bizkaia
HBS3 commands using CLI
Hi
I have some tasks outside the NAS (other systems) with an unknown duration.
When that task finishes it generates a flag file.
Using a scheduled CRON task I check for the existence of that file and by console launch the sync task [JobXX] ( qsync -j:JobXX -c:/file.conf )
Since HBS3 has been updated, the console command doesn´t work because qsync.conf doesn't exist.
In HBS3 definition tasks, there are only time schedules or after running other HBS3 tasks.
How can I launch those tasks using console?
I have some tasks outside the NAS (other systems) with an unknown duration.
When that task finishes it generates a flag file.
Using a scheduled CRON task I check for the existence of that file and by console launch the sync task [JobXX] ( qsync -j:JobXX -c:/file.conf )
Since HBS3 has been updated, the console command doesn´t work because qsync.conf doesn't exist.
In HBS3 definition tasks, there are only time schedules or after running other HBS3 tasks.
How can I launch those tasks using console?
-
- First post
- Posts: 1
- Joined: Fri Aug 23, 2019 6:38 pm
Re: HBS3 commands using CLI
Did you manage to discover how to configure and start tasks?
-
- Getting the hang of things
- Posts: 50
- Joined: Sat Nov 21, 2009 7:31 am
- Location: Bizkaia
Re: HBS3 commands using CLI
No, i didn’t
I'm still looking for how to do it
Un saludo
Agur eta ondo ibilli
Mon (TS-469Pro, TVS-673, QBoat Sunny y TS-453Be)
I'm still looking for how to do it
Un saludo
Agur eta ondo ibilli
Mon (TS-469Pro, TVS-673, QBoat Sunny y TS-453Be)
-
- New here
- Posts: 9
- Joined: Mon Dec 22, 2014 12:41 pm
Re: HBS3 commands using CLI
has anyone figured this out? I am also trying to find this answer.
-
- Getting the hang of things
- Posts: 50
- Joined: Sat Nov 21, 2009 7:31 am
- Location: Bizkaia
Re: HBS3 commands using CLI
Hi
I have asked the Spanish SAT of qnap, and they didn't know it either
Un saludo
Agur eta ondo ibilli
Mon (TS-469Pro, TVS-673, QBoat Sunny y TS-453Be)
I have asked the Spanish SAT of qnap, and they didn't know it either
Un saludo
Agur eta ondo ibilli
Mon (TS-469Pro, TVS-673, QBoat Sunny y TS-453Be)
-
- New here
- Posts: 2
- Joined: Mon Mar 25, 2019 4:23 pm
Re: HBS3 commands using CLI
it depends very much on the target of the backup on. If the HBS server of the target has the version 2.1xxx e.g. with RTRR backup the command generates
/usr/bin/RTRR -C:/etc/qsync/qsynchbs3.conf -J:Job0
With new HBS 3 as target the configuration data are stored in the mariadb and are read out by various qsync servers there is no explicit HBS command. I have figured that out so far.
Unfortunately there is no information from QNAP for the scheme nor a command option to start backups... too bad.
You can reset the password of the root of the database but it may be that you violate the upgrade or consistency.
Sorry...
/usr/bin/RTRR -C:/etc/qsync/qsynchbs3.conf -J:Job0
With new HBS 3 as target the configuration data are stored in the mariadb and are read out by various qsync servers there is no explicit HBS command. I have figured that out so far.
Unfortunately there is no information from QNAP for the scheme nor a command option to start backups... too bad.
You can reset the password of the root of the database but it may be that you violate the upgrade or consistency.
Sorry...
-
- Getting the hang of things
- Posts: 50
- Joined: Sat Nov 21, 2009 7:31 am
- Location: Bizkaia
HBS3 commands using CLI
Hi
I am thinking to use a bash script.
In this script, I will use rsync, as a standard command and forgetting to use the HBS3 proprietary program
Un saludo
Agur eta ondo ibilli
Mon (TS-469Pro, TVS-673, QBoat Sunny y TS-453Be)
I am thinking to use a bash script.
In this script, I will use rsync, as a standard command and forgetting to use the HBS3 proprietary program
Un saludo
Agur eta ondo ibilli
Mon (TS-469Pro, TVS-673, QBoat Sunny y TS-453Be)
-
- New here
- Posts: 2
- Joined: Mon Mar 25, 2019 4:23 pm
Re: HBS3 commands using CLI
Hi ,
yes I see that's also a solution... But its really sad to fallback to an bash script with rsync if you have an so a backup program with a lot of functionalities for free .. but without controlling from CLI.
I used a bash script for switch on my backup NAS Server (over WOL) make backup and switch down again. It work's fine till upgrade to HBS 3.
yes I see that's also a solution... But its really sad to fallback to an bash script with rsync if you have an so a backup program with a lot of functionalities for free .. but without controlling from CLI.
I used a bash script for switch on my backup NAS Server (over WOL) make backup and switch down again. It work's fine till upgrade to HBS 3.
-
- Getting the hang of things
- Posts: 50
- Joined: Sat Nov 21, 2009 7:31 am
- Location: Bizkaia
Re: HBS3 commands using CLI
Hi
You are right
Some years ago, there was a tv spot that said “Power without control is useless” (la potencia sin control no sirve de nada).
And that happens to us with hsb3
Un saludo
Agur eta ondo ibilli
Mon (TS-469Pro, TVS-673, QBoat Sunny y TS-453Be)
You are right
Some years ago, there was a tv spot that said “Power without control is useless” (la potencia sin control no sirve de nada).
And that happens to us with hsb3
Un saludo
Agur eta ondo ibilli
Mon (TS-469Pro, TVS-673, QBoat Sunny y TS-453Be)
-
- New here
- Posts: 2
- Joined: Mon Jan 05, 2015 12:05 am
Re: HBS3 commands using CLI
I really wanted to trigger from CLI so I investigated how the GUI does and imitated this in this script. Replace variables, find out job GUID and start the script with guid as param:
Code: Select all
#!/bin/bash
#Starts with job guid as param, find guid here: http://$nasIp/cc3/v1/users/system/jobs
nasIp="192.168.1.x"
user="user"
password="password"
auth=$(curl "http://$nasIp/cgi-bin/authLogin.cgi" -H "Content-type: application/x-www-form-urlencoded" --data-urlencode "user=$user" --data-urlencode "serviceKey=1" --data-urlencode "pwd=$(echo -n $password | base64)" --silent)
sidXML=$(echo "$auth" | grep -Eo "<authSid>(.+?)</authSid>")
sidStrip="${sidXML/<authSid><![CDATA[/}"
sid="${sidStrip/]]><\/authSid>/}"
curl "http://$nasIp/cc3/v1/users/system/jobs/$1?command=start" -H "X-QNAP-SID: $sid" --data-raw '{}' --silent
-
- Getting the hang of things
- Posts: 50
- Joined: Sat Nov 21, 2009 7:31 am
- Location: Bizkaia
Re: HBS3 commands using CLI
Hello
Thanks [mention]rullen [/mention] for your work
today in the afternoon I’ll try it and i’ll count the results
Un saludo
Agur eta ondo ibilli
Mon (TS-469Pro, TVS-673, QBoat Sunny y TS-453Be)
Thanks [mention]rullen [/mention] for your work
today in the afternoon I’ll try it and i’ll count the results
Un saludo
Agur eta ondo ibilli
Mon (TS-469Pro, TVS-673, QBoat Sunny y TS-453Be)
-
- Starting out
- Posts: 21
- Joined: Sun Jul 24, 2016 11:45 pm
- Location: New York, I love you but
- Contact:
Re: HBS3 commands using CLI
I realize this post is a couple years old, but rullen's method looks like it will work for me. I had trouble with the bash script as it was shared, but that might have just been a mistake on my part, and I got the HTTP requests working in another tool. Thanks!