Skip to content

Tag: bash

Bash script commands not running

I have seafile (http://www.seafile.com/en/home/) running on my NAS and I set up a cron tab that runs a script every few minutes to check if the seafile server is up, and if not, it will start it The script looks like this: running /home/simon/seafile/seafile-server-latest/seafile.sh start and /home/simon/seaf…

Until Loop not working as expected

I’m currently learning Linux and as an homework, we have to create a few basic shell scripts. Nothing especially complicated but this one is giving me headaches. Here’s my code : Basically, I have another script called afficher.sh (I’m french so don’t mind the french language used) and…

list file key-pair sorted by time

I need to sort a filename pair sorted by time. Every file starts with AUSZUG or UMSATZ (and some numbers after). But the problem is that I cannot sort it by just time because some files can be uploaded (created) not as pair. For example, default sort: You can see, UMSATZ pair for AUSZUG_5785745789.TXT.GPG are…

how do I limit the number of history items in bash? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers. This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack …

Obtaining file names from directory in Bash

I am trying to create a zsh script to test my project. The teacher supplied us with some input files and expected output files. I need to diff the output files from myExecutable with the expected output files. Question: Does $iF contain a string in the following code or some kind of bash reference to the file…

how to execute init scripts from the command line using ssh

Above mentioned code works fine and displays all the contents of the test directory folder but this code fails It does not start the mysql server, I have login in to server and use the same command to start the mysql server Can any one explain this behaviour ? what I am doing wrong bit puzzled 🙁 Answer Do som…