Skip to content

Tag: terminal

Terminal – current directory symbol [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 …

Linux command for public ip address

I want command to get Linux machine(amazon) external/public IP Address. I tried hostname -I and other commands from blogs and stackoverflow like and many more. But they all are giving me internal IP Address. Then I found some sites which provides API for this. Example : curl http://ipecho.net/plain; echo But …

How to start java program with hidden terminal

How can i create shell script for linux, Which will start my java program and then exit itself Like:- create new process with no terminal-> java “Test”. exit terminal itself. i have tried with Fork and exec but i couldn’t get any of it please help me Answer I solved this by using Python s…

How to terminate process from Python using pid?

I’m trying to write some short script in python which would start another python code in subprocess if is not already started else terminate terminal & app (Linux). So it looks like: Have problem of lacking knowledge to name proces by pid which app reads from file “.proc”. The other prob…

Clearing output of a terminal program in Linux C

I want to clear the output of a C program produced with printf statements. I want to clear only one line, for example: [source] [terminal] [I hope] I will “DDDDDDDDDDDDDD” line in write other string. I just want the above A, B, C sentences to left. Only clear D sentences to change the other senten…

Get the MySQL path

I tried googling to get the MySql path, but it was unsuccessful. Is there a unix command, where I can find the MySQL database directory path? Answer Try this query, SHOW VARIABLES LIKE ‘datadir’;