Questions tagged [process]

A process is an instance of a computer program that is being executed.

Filter by
Sorted by
Tagged with
2
votes
2answers
43 views

See to what the output of a process is redirected

I have a process that should have his output redirected to output.txt. Unfortunatly the output does not go to this file. First i checked if I called it from another directory, but there is no output....
0
votes
0answers
19 views

How to identify GPU processes (or processes in general) that have been idle for the last x consecutive hours?

How would one go about identifying processes (gpu processes specifically) that haven't done anything in the last 2 hours - for example? The problem I'm having stems from multiple users trying to use a ...
0
votes
1answer
142 views

Bash Creates Child Process Using && and not with ; for a nohup programm

I have a macbook (default shell is zsh) I have an executable python script (srcript1.py). I use another executable script (called starter) that runs script1.py when my computer starts, the terminal ...
1
vote
3answers
143 views

Why a change of dir can't be made in a separate process?

Why we can't create a process which change the current working dir. Just like cd command does?
0
votes
1answer
44 views

A ps command with the relevant options that shows the state / status of only ONE process

I start 2 processes in the background: xeyes and xclock -update 1. When I run this commane: ps T o pid,tty,time,args,state (this for to output state) it lists: PID TT TIME COMMAND ...
0
votes
1answer
24 views

Checking the bash process in Terminal 1 is the parent process of a child process, FROM terminal 2?

I have 2 terminals open. In terminal 1 I have bash running, then I run xlogo; xlogo is the child of course. If I type ps T o user,pid,tty,args,ppid it gives me: USER PID TT COMMAND ...
0
votes
1answer
58 views

How to switch from one process to another process and kill the first process

I have the following scenario, I have two programs running one in the background and one in front. The back program is doing some stuff for the front program. once the back program has done the ...
0
votes
2answers
41 views

How to monitor running programs with open ports?

Ok, so I want to monitoring running programs on Debian. For example I have a running several program on my instance and I can get output of netstat -plnt and see what is program and their ports. ...
0
votes
0answers
42 views

how to kill PHP PID processes?

i have shared hosting which allows maximum 25 processes. after it reaches 25, site shows 500 internal error. in cpanel i manually kill the process. Which script can work to kill all php PID processes ...
3
votes
1answer
195 views

/proc/[pid]/fd/[0, 1, 2]: No such file or device - even though file exists

I'm trying to access a process' stdio streams from outside its parent process. I've found the /proc/[pid]/fd directory, but when I try $ cat /proc/[pid]/fd/1 I get a No such file or device error. I ...
0
votes
0answers
54 views

what is the best way to remove unused cgroups?

I have a master process that creates so many child processes on demand and jail each of them with a cgroup (say cpu cgroup). What is the best way to remove the unused cgroup hirearchy. Currently i am ...
0
votes
1answer
92 views

kill -9 $PPID kills the process?

I read that killing the parent process will get the child process attached to init (PPID=1). To test this I created three shells and sent the second one the kill signal: # first process "a" ...
6
votes
1answer
200 views

How to make `top` only display a group of processes matching a specific pattern?

I want to show all processes whose command line includes .*git.* using top. I've considered the following command: top -p $(pgrep -d',' -f '.*git.*') However, the above command has several caveats: ...
0
votes
1answer
573 views

How to kill all (child) processes in the process tree rooted at a specific process, but not the process itself?

I have a python process, which spawns a git (git clone) child process, which in turn spawns several child processes itself. Here, I want to kill all processes in the process tree rooted by git, ...
2
votes
1answer
50 views

How does a new process executed in Bash always has the same environment variables?

A while ago I was exploring a simple C program's ELF binary using GDB. I saw that the environment variables that are printed when I run printenv in the terminal are also present at the top of the ...
0
votes
0answers
250 views

How can I make a terminated process terminate all of its children recursively using multiprocessing.Process in Python3?

I want to spawn child processes inside child processes, and make it so, that if a parent is terminated, then each of its children is terminated recursively. I'm currently using Python as the ...
0
votes
1answer
42 views

fork function flags each page in both processes as read-only? [closed]

I was reading a textbook which talks about how fork() work with virtual memory as: When the fork function is called by the current process, the kernel creates various data structures for the new ...
0
votes
1answer
52 views

How to prevent Linux from using a specific PID number for any newly created process?

I'd like to introduce a solution for the problem originally described here: pkill is not an atomic operation, not by a long stretch. In the while since pkill -P 666 foo has determined that pid 667 is ...
0
votes
1answer
45 views

Loading executable object files and creating private area [closed]

I was reading a textbook on virtual memory and it says: Any Linux program can invoke the loader by calling the execve function which does: Delete the existing area structs in the user portion of the ...
-1
votes
1answer
65 views

the structure of the virtual memory of a Linux process

I'm reading a textbook which shows virtual memory as: Linux also maps a set of contiguousvirtual pages (equal in size to the total amount of DRAM in the system) to the corresponding set of contiguous ...
3
votes
4answers
202 views

How to avoid killing a wrong process when using PID number for killing?

I do start a long-running background process within a Bash script. I save the PID number inside a variable after sending the process to background and I use that PID number to kill that process when ...
-1
votes
1answer
95 views

how come a virual address is only 48 bits rather than 64 bits? [closed]

I was reading a book which talks about virtual memory: Intel Core i7 supports a 48-bit (256 TB) virtual address space and a 52-bit (4 PB) physical address space below is my question Q1-since we ...
0
votes
2answers
73 views

Why can't some processes run in the background in Linux terminal while others can, despite all being able to print to the terminal?

I use Linux terminal in Ubuntu. When I write seq 100 1 | less & to run it it in the background, it just stops. I used other ways to run it on background too, like using bg [jobnr] but it just ...
0
votes
0answers
7 views

Kill background process bash not working from current shell [duplicate]

I'm doing trap to kill subprocesses of script and it's working perfectly: myscript.sh trap "kill 0" EXIT ./someProcessA & ./someProcessB & the problem that I don't understand why ...
0
votes
0answers
14 views

Default specific processes to higher priorities with lutris or otherwise?

I'm running Manjaro XFCE (20.1 at the time of writing) and I would like to make lutris, or some other third-party program, automatically launch all games with a default niceness value of -6 or ...
0
votes
1answer
117 views

How to get PID from within bash shell script

I have the following code that submits several subjobs withing a docker container: #!/bin/bash for file in "all files of a given type"; do docker exec -itd "docker container"...
2
votes
0answers
123 views

How do I find the PID of the active window, where the application is a flatpak?

I can find the information easily for regular applications with something like: xdotool getactivewindow getwindowname xdotool getactivewindow getwindowpid VLC media player 28448 However with the ...
1
vote
0answers
34 views

Why does Message+ randomly pop up on my processes on Kali?

I watch my network using "top" and I notice message+ keeps randomly popping up for about 1-2 seconds then disappears. What is this and why is this happening? I can't find anything on it.
1
vote
1answer
168 views

Call only async-signal-safe functions in signal handlers? [closed]

I'm new to signal and signal handler and I was reading a book which says Call only async-signal-safe functions in your handlers. A function that is async-signal-safe, or simply safe, has the property ...
0
votes
0answers
51 views

Why bash need job control?

Why Unix systems need job control? So for example, we can use the process number or job number(jobspec) with the kill command. $ sleep 101 & [1] 19 $ sleep 102 & [2] 20 $ jobs -l [1]- 19 ...
0
votes
1answer
59 views

how does a process group have process id?

I'm reading a textbook which discusses process group and shell and it says: Unix shells use the abstraction of a job to represent the processes that are created as a result of evaluating a single ...
0
votes
1answer
41 views

Three Questions on Child Shells: Lifespan and Creation

Is a child shell's life over shortly after it's created? I.e., do its assets get replaced by the process that is going to be run in it? Say we've run grep -r "something" in bash, so our ...
3
votes
1answer
248 views

Does /proc/ contains tid?

I have process id 1234. This process contains thread id 1235. When I use ls -l /proc I see only the pid (1234) but when I open the thread status file using cat /proc/1235/status I can see data. Why is ...
-1
votes
1answer
102 views

How to find out on which core a thread is running on?

Let's say we have a CPU-intensive application called multi-threaded-application.out that is running on top of Ubuntu with a PID of 10000. It has 4 threads with tid 10001, 10002, 10003, and 10004. I ...
1
vote
0answers
20 views

Stop automatic application execution on graphical login

I use Manjaro 20, and have changed the display manager from LightDM to SDDM, out of that and installing normal applications, I haven't changed anything on the system. For some reason xfce4-terminal ...
3
votes
2answers
411 views

When I do double fork a process, is the detached process still in the same process group?

As titled, extra question, can process group have descendants?
1
vote
2answers
256 views

How to start a realtime process?

I looking for a way to start a real-time process or set a running process as a real-time process.
0
votes
2answers
50 views

Stop specific processes from heating up my system's CPU

I have a process doing some computation the whole time. It causes my system's CPU to heat up and the fan to spin faster. I want this process to run, but with a low priority. I don't want my system to ...
0
votes
0answers
245 views

How to kill a Python process within an SSH session

This question involves running a bash script, say helloworld.sh, which executes an MPI mpirun command which in turn runs a Python program, say helloworld.py, using mpi4py. The bash command is used in ...
1
vote
2answers
378 views

Is it possible for a kernel space thread or process to be child of a userspace process?

I am kind of a newbie when it comes to the Linux Kernel, but I was reading this article about fibrils where it mentions that they are (or were? not sure if they were ultimately kept in the Kernel) ...
0
votes
1answer
64 views

Why sometimes when i run a program in terminal, it won't run in the terminal?

Suppose i have two applications called firefox and arduino. At first, I typed firefox to the terminal and i still can use the terminal as usual. But when i typed arduino , i couldn't use the terminal ...
-1
votes
2answers
200 views

best range for custom exit code in linux? [closed]

Here I am developing an application that can exit for various custom reasons. What is the best range for a custom exit code (like 150-200)? I know this opinion-based but still i wanted to know the ...
0
votes
1answer
49 views

Automatic Process kill process problem

I am using MX linux for a few days and I found a problematic behavior. Suddenly sevaral processes were killed automatically. For this, I had to face many problems. Is there any way to stop it? I don't ...
0
votes
0answers
43 views

How to open a running instance of a program in Debian?

When I try to open VeraCrypt I get this error: VeraCrypt is already running.. How can I open the running instance?
0
votes
1answer
55 views

what will happen if receiver unable to handle data velocity through socket?

I have two processes P1 (sender) and P2 (receiver). P1 uses unix-domain-socket (UDS) to send data to P2. what will happen if P1 sends data at the rate of 100 messages/second and P2 is capable to ...
1
vote
1answer
79 views

PID of a nested command in a subshell

Okay, I've got a program I'm trying to fix, for lengthy reasons a rewrite isn't the greatest option... So, I've been up for 8 hours trying to solve this and I'm completely stumped. I'm trying to get ...
1
vote
0answers
24 views

How to retrieve a process cmdline after setproctitle?

I tried looking at how sshd spawns its processes and caught something like sshd: [priv] in the process list. When I tried reading /proc/pid/cmdline I got the sshd: [priv] name but I was wondering how ...
1
vote
0answers
18 views

Get the script command of a child process?

Is there a way to retrieve the script command responsible for a child execution? For example: If I run in a script called runX arg1 arg2 (X being the process name) [some code] X arg3 arg4 now when I ...
0
votes
0answers
42 views

Keeping the process alive after launched passing command to gnome-terminal

I'm trying to keep alive the TimezoneClock process after that I've passed the commands to gnome-terminal. Before I've tried without the terminal for the start-up but it doesn't works, then now I'm ...
-1
votes
1answer
253 views

Port 3000 is always being hogged by grafana-server

I need port 3000 free for my dev work. But it's being used by grafana-server, that I don't remember ever installing. We do use it within our company so perhaps at some point it has been added to ...

1 2
3
4 5
48