Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [exit-status]

Use this tag If your question revolves around determining or utilizing the exit status (return code) of a command. Common syntax involves the $? variable and the && and || symbols.

3
votes
2answers
727 views

systemd status=127 for /usr/bin/install when trying to start MariaDB

I just upgraded my MariaDB installation to 10.2. When I now try to start the service, it tells me it failed an checking the status shows me this rather strange message: root@server # systemctl status ...
2
votes
2answers
365 views

How to detect an error using process substitution

This question is similar to the following link, but focused on using the command line (bash shell). Using a simple example, when doing the following command: $ cat <(date); echo $? Fri Jul 7 21:...
1
vote
1answer
634 views

How to get return value from MATLAB function

I am calling a MATLAB function with a bash script matlab -nodesktop -nosplash -nodisplay -r "matlabfunction input1 input2; quit" I am trying to get a one digit return value from the matlab function, ...
1
vote
1answer
2k views

lftp return code

I have written below code to get listing from a remote server. echo "set xfer:log yes" > batchfile.txt echo "set xfer:log-file Templogfile1.txt">> batchfile.txt echo "open -p $rport -u $...
1
vote
0answers
95 views

What does it mean when Duplicity exits with exit status 23?

I'm running Duplicity for backup of my desktop to a remote storage. Everything has been working fine, but now I see in my log that Duplicity has been exiting with exit status 23 for a couple of runs. ...
1
vote
0answers
109 views

How to find status of init.d exit scripts which return 0 on failure?

It seems that many init.d scripts return 0 on failure, in spite of these recommendations. For example, in nginx, running directly: /usr/sbin/nginx -t # returns 1 (with a bad config) and ...
1
vote
0answers
546 views

whether the ssh command successful or not?

I spawned ssh in expect script. in the script i have to check the exit status of ssh command on local machine to make some condition in that script using if/else. spawn ssh user@192.168.1.1 ...
0
votes
0answers
40 views

How to enter and leave a man page in a script

I want to run a script that enters a man page and leaves it. Something like (in pseudo-code) $ man man q How can I do such a thing? Preferably the exit code will be 0. More generally how do I do ...
0
votes
0answers
31 views

C++ script on Spark Cluster throws exit status 132

I'm trying to run a c++ program on spark cluster by using the rdd.pipe() operation but the executors throw: java.lang.IllegalStateException: Subprocess exited with status 132. The spark jar runs ...
0
votes
0answers
51 views

Is it possible to “coax” arbitrary core *nix utilities into returning a non-zero exit status even when successful?

I am running bash scripts and executing bash commands on remote systems using Connectwise Automate (formerly LabTech). These systems are both Linux and MacOS. Connectwise Automate (CWA) has some ...
0
votes
0answers
927 views

Getting message “No Such File Or Directory” message with SFTP connection but file is on the server

I'm trying to figure out and I would like to know if some of you experienced this before. I have my SFTP script (before it was FTP, and was migrated to SFTP), when I'm sending a file to the client ...