I’m making a PHP page with the purpose of creating and activating Apache VirtualHost files. The pages generates the files and places it in /etc/apache2/sites-available/. After that a shell script is called by with: shell_exec(“/bin/sh /usr/local/bin/myscript.sh”); myscript.sh: The script see…
Tag: linux
GNU Parallel | pipe command
I am completely new in using GNU parallel and I need your advice in running the command below using GNU parallel: I will run this command on a list of files (.bin), so what is the best (fastest) approach to achieve that using GNU parallel noting that the output of the first part of the command (/home/admin/Gf…
Windows 7/10 – Make Application launch on a different display
I am porting a Linux application to windows , there are two executable’s which need to be launched on primary and secondary displays respectively. In Linux its done through #!/bin/sh script,something like display_start_dualhead LVDS 800 480 DVI 1024 768 24 export screen_main=$LVDS export screen_secondar…
How can I build a standalone MQSeries client under Linux using the C API?
IBM offer an installable MQSeries Client software that allows you to access queue managers on remote hosts. They also offer some C-callable libraries that let you do messaging from a C application. My problem is that I don’t have admin access on the hosts I plan to test-deploy on, and getting an applica…
Catching SIGSEGV when triggered by corrupt stack
I’ve been working on some buggy code and wanted to install a SIGSEGV handler to get more information about the crash. However, I noticed that my handler is not invoked. I’ve been looking for a reason and it seems it has to do with a corrupt stack pointer value (it’s not getting masked for su…
PHP Calling shell_exec on a bash script running a background process times out
I have a bash script with a few lines similar to the following Then I call that from a PHP script return shell_exec(“/path/to/bash/script arguments”); Now, when I do that, the command is run successfully, and outputfile.txt contains “Ran Command”. However, the PHP script times out afte…
How to avoid cmake to read in its “system cache” $HOME/.cmake/
When I run cmake with some projects such as caffe or gflags, it writes some information at the system level. Specifically, on a linux system, it generates some directories such as $HOME/.cmake/Caffe and $HOME/.cmake/gflags My problem is that this information is hereafter used for any project I compile. As a c…
Installing swirl on linux mint
I am trying to install swirl in RStudio and it is not working it reads: The downloaded source packages are in ‘/tmp/Rtmp9gKFfm/downloaded_packages’ When I try to load it, it says: Error in library(swirl) : there is no package called ‘swirl’ I am running Linux Mint 18 Cinnamon 64-bit 3.0.7 R version 3.2.3 Answ…
2 program get same udp packets from a port
there is a server will send some UDP packets to my localhost, for example: if it send some UDP packets to my localhost and destination port is 5000. and there will have a client program to receive it on port 5000. but, what I want is to create another program, it will try to receive the same packets on port
Acessing to /root folder on BeagleBone (Debian) after /usr directory was deleted
I have had some .cpp programs in root directory of my BeagleBoneBlack (Debian). Due to a studpid accident a /usr directory was deleted on my BeagleBone. It make sense for me now, that I can not access the BeagleBone anymore. What I can do is to boot the BeagleBone from SSD-card, but of course I come in this c…