I am trying to prevent bash to ask for sudo permission to run the port command (OSX packet manager) adding it to visudo. I basically tried to follow this SO thread but I still get an error The same selfupdate command runs smoothly if I sudo it. My visudo has the following lines and I also tried susbtituitng t…
Tag: linux
grep with star symbol
What is the difference between grep commands: and what is different if I search text as “text”. Answer grep requires (at least) two arguments — what you are searching for, and where you are searching for it. If the second argument is not provided, then it will use stdin instead. grep text* i…
Cannot pass parameters to slaves with distributed JMeter setup with Maven and linux
Using JMeter 2.13, Maven and Linux in all servers. Not running any tests from gui or command line, Maven is used! Have a test plan with a lot of parameters that are set and passed from Maven execution in Jenkins to the JMeter test plan. Using “-J” in Maven to set the input parameters. Works fine i…
Memory used by compiling a code
I use time command to measure the time used to execute a file as: My question: are there any command like time can give the memory used by executing an executable file in linux? Answer You can use /usr/bin/time -v ./filename. It will print a lot of information including memory use. Note: Will use the shell bu…
Application is getting killed without any reason. Suspecting high BSS. How to debug it?
I have been running my application successfully in CentOs6.6. Recently, the hardware(motherboard and RAM) was updated and my application is getting killed now without any reason at all. File and ldd output Output of strace GDB While debugging, observed that the bss memory is huge(~6GB). The system has 4GB RAM…
Why won’t a chunck of this program run in Linux but will on Windows?
So I had to build a tiny little game that asks players to pick a number and see if they guess what the computer picks. It has 2 players and each can pass their turn to the other. One of the stipulations is that my professor is running a linux OS and has said if it doesn’t work on that
sudo: effective uid is not 0, is sudo installed setuid root? (on mac os x 10.12)
So I’m a bit of a terminal noob so bear with me but I was trying to update brew to install something, so I ran: brew update and got Error: /usr/local must be writable! Wasn’t really sure what that was about so I tried running sudo brew update and got sudo: effective uid is not 0, is sudo installed…
cURL empty request data if https connection
I try to send the file via POST. Before that i used http connection and everything worked. But now var_dump($_REQUEST); in my php-file returns an empty array. This my curl log: $ curl -X POST -F “id=1” -F “file=@/tmp/file.txt” https://MY_DOMAIN/save_file.php -v Hostname was NOT found i…
Python flask wont render multiple templates, possibly HTML issue
Updated question: my flask web page is working well, however i am currently editing my 3rd page and its doing something i cant understand. when i click on the third tab of my web app, the URL goes localhost/DC2/DC5, whereas i need it to go localhost/DC5. Im not sure why its jumping through the first page. Her…
Sending payload with sigaction
how can I use sigaction such that a process can send a payload with the signal that can be retrieved by the receiving process? Answer You use a realtime signal (SIGRTMIN+0 to SIGRTMAX-0), so that the signals are queued, and you have a much lesser chance of missing one. (Standard signals are not queued, so if …