I have tried to get the kill table in arch linux normally kill -l worked in Debian based linux but not working in manjaro can some one help ?
Is the package psmisc installed? This package contains the kill command. To install the package run in the terminal sudo pacman -S psmisc
The xkill command only works on Xorg. If you are using Wayland this command will not work. To work on Xorg the xorg-xkill package must be installed with sudo pacman -S xorg-xkill.
In Wayland you can use the kill command. To check the process PID you can use the ps aux command.
Example:
ps aux | grep program_name
kill -9 process_number
ps aux | grep nautilus
kill -9 25704
I apologize if I didn't understand your question.
Related
brew install --cask another-redis-desktop-manager
Error message: damaged and can’t be opened. You should move it to the Trash
After brew install, use the commands:
sudo spctl --master-disable
sudo xattr -rd com.apple.quarantine /Applications/Another\ Redis\ Desktop\ Manager.app
sudo spctl --master-enable
actually you need only one command:
sudo xattr -rd com.apple.quarantine /Applications/Another\ Redis\ Desktop\ Manager.app
Building my container using docker and wsl2 I wanted to see what happens. Running htop in wsl only shows the CPU usage, but none processes running in my containers.
The only information searching for htop, docker and wsl2, the only thing I could find was this archived and unrelated reddit-thread: https://www.reddit.com/r/bashonubuntuonwindows/comments/dia2bw/htop_on_wsl2_doesnt_show_any_processes_while_ps/
Docker does not run in your default WSL-distro, but in a special Docker-Wsl-distro. Running wsl -l shows the installed distros:
Ubuntu (Standard)
docker-desktop
docker-desktop-data
Docker desktop is based on alpine and you can run top right out of the box:
wsl -d docker-desktop top
If you want htop, you need to install it first:
wsl -d docker-desktop apk update
wsl -d docker-desktop apk add htop
Running
wsl -d docker-desktop htop
will now give you a nice overview of what is happening in your docker-containers:
I agree with #Morty.
The following commands give you the list for windows
wsl -l
Then you can run either of the following command
wsl -d docker-desktop ps
wsl -d docker-desktop top
This question already has an answer here:
Enable Systemd in WSL 2
(1 answer)
Closed 2 months ago.
I need to reload the daemon using systemctl command in ubuntu terminal on window 10. I attached the error I received.
The error:
bashdos#yana:~$ systemctl
System has not been booted with systemd as init system (PID 1). Can't operate.
WSL doesn't have systemd implemented therefore in Ubuntu you need to run for example service start ssh or you can call the binary directly such as /etc/init.d/ssh start/stop/restart.
I had this problem running WSL 2
the solution was the command
$ sudo dockerd
Open other terminal and try it
$ docker ps -a
if after that you still have a problem with permission, run the command:
$ sudo usermod -aG docker your-user
I'm running the following command:
echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p
and getting this error:
sysctl: cannot stat /proc/sys/fs/inotify/max_user_watches: No such file or directory
I'm not sure what to do about this. I'm running WSL on Windows 10 Build 1709, OS Build 16299.309
max_user_watches was not implemented in 1709. It apperars to be fixed in 1803. For more details you can refer to this bug:
https://github.com/Microsoft/WSL/issues/1705
I am experimenting with Docker and am very new to it. I am struck at a point for a long time and am not getting a way through and hence came up with this question here...
Problem Statement:
I am trying to create an image from a docker file containing Apache and lynx installation. Once done I am trying to access tomcat on 8080 of the container which is in turn forwarded to the 8082 of the host. But when running the image I never get tomcat started in the container.
The Docker file
FROM ubuntu:16.10
#Install Lynx
Run apt-get update
Run apt-get install -y lynx
#Install Curl
Run apt-get install -y curl
#Install tools: jdk
Run apt-get update
Run apt-get install -y openjdk-8-jdk wget
#Install apache tomcat
Run groupadd tomcat
Run useradd -s /bin/false -g tomcat -d /opt/tomcat tomcat
Run cd /tmp
Run curl -O http://apache.mirrors.ionfish.org/tomcat/tomcat- 8/v8.5.12/bin/apache-tomcat-8.5.12.tar.gz
Run mkdir /opt/tomcat
Run tar xzvf apache-tomcat-8*tar.gz -C /opt/tomcat --strip-components=1
Run cd /opt/tomcat
Run chgrp -R tomcat /opt/tomcat
Run chmod -R g+r /opt/tomcat/conf
Run chmod g+x /opt/tomcat/conf
Run chown -R tomcat /opt/tomcat/webapps /opt/tomcat/work /opt/tomcat/temp opt/tomcat/logs
Run cd /opt/tomcat/bin
Expose 8080
CMD /opt/tomcat/bin/catalina.sh run && tail -f /opt/tomcat/logs/catalina.out
When the image is built I tried running the container by the two below methods
docker run -d -p 8082:8080 imageid tail -f /dev/null
While using the above, container is running but tomcat is not started inside the container and hence not accessible from localhost:8082. Also I do not see anything if I perform docker logs longcontainerid
docker run -d -p 8082:8080 imageid /path/to/catalina.sh start tail -f /dev/null
I see tomcat started when I do docker logs longconatainrid
While using the above the container is started and stopped immediately and is not running as I can see from docker ps and hence again not accessible from localhost:8082.
Can anyone please tell me where I am going wrong?
P.s. I searched a lot on the internet but could not get the thing right. Might be there is some concept that i am not getting clearly.
Looking at the docker run command documentation, the doc states that any command passed to the run will override the original CMD in your Dockerfile:
As the operator (the person running a container from the image), you can override that CMD instruction just by specifying a new COMMAND
1/ Then when you run:
docker run -d -p 8082:8080 imageid tail -f /dev/null
The container is run with COMMAND tail -f /dev/null, the original command starting tomcat is overridden.
To resolve your problem, try to run:
docker run -d -p 8082:8080 imageid
and
docker log -f containerId
To see if tomcat is correctly started.
2/ You should not use the start argument with catalina.sh. Have a look at this official tomcat Dokerfile, the team uses :
CMD ["catalina.sh", "run"]
to start tomcat (when you use start, docker ends container at the end of the shell script and tomcat will start but not maintain a running process).
3/ Finally, why don't you use tomcat official image to build your container? You could just use the :
FROM tomcat:latest
directive at the beginning of your Dockerfile, and add you required elements (new files, webapps war, settings) to the docker image.