Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Error] ping command does not work. #1118

Closed
s-kesh opened this issue Dec 26, 2023 · 8 comments
Closed

[Error] ping command does not work. #1118

s-kesh opened this issue Dec 26, 2023 · 8 comments
Labels
bug Something isn't working

Comments

@s-kesh
Copy link

s-kesh commented Dec 26, 2023

Describe the bug
ping to a address does not work.
I have a fedora distrobox on debian 12 host. When I try to ping to a address, it shows following error

$ ping -v 8.8.8.8
ping: socktype: SOCK_RAW
ping: socket: Operation not permitted
ping: socktype: SOCK_RAW
ping: socket: Operation not permitted
ping: => missing cap_net_raw+p capability or setuid?

ping works on the host.

To Reproduce
Use ping on the container.

Expected behavior
ping should work.

Logs
ping.log
podmanerr.log
podman.log

Desktop (please complete the following information):

  • podman
  • 4.3.1
  • 1.6.0.1
  • debian 12.4 (kernel: 6.1.0-16-amd64)
  • Mannualy installed distrobox using curl.

Additional context
None

@s-kesh s-kesh added the bug Something isn't working label Dec 26, 2023
@pavinjosdev
Copy link
Contributor

Could you try in a distrobox created using --unshare-netns flag?

@89luca89
Copy link
Owner

89luca89 commented Feb 3, 2024

Hi @s-kesh can you provide more info on how the container was created? I'm not able to reproduce this issue

@89luca89 89luca89 closed this as not planned Won't fix, can't repro, duplicate, stale Feb 19, 2024
@s-kesh
Copy link
Author

s-kesh commented Feb 20, 2024

Sorry for such a late reply. I was busy with some work.
I created the the distrobox with

distrobox create --image registry.fedoraproject.org/fedora-toolbox:39 --name fedbox

Let me know if you need some other information. If you can not reproduce it, maybe it is a problem with debian.

@nafiz1001
Copy link

nafiz1001 commented Mar 9, 2024

I'm on Debian 12 (Bookworm), and I also have a similar issue.

I created distrobox with distrobox-create -i debian:bookworm --unshare-netns

The --unshare-netns did kinda help, but then I was getting another issue.

nafiz@debian-bookworm:~$ ping google.com
PING google.com (x.x.x.x) 56(84) bytes of data.

It would just hang on the first PING line.

Weirdly enough, I can install packages with apt just fine.

Edit: my issue might be related to #1075. Actually no, I can't even ping 8.8.8.8

@nafiz1001
Copy link

nafiz1001 commented Mar 9, 2024

@s-kesh Can you reopen the issue? 😅

@pavinjosdev
Copy link
Contributor

@nafiz1001 Are you using the latest distrobox version 1.7.0 and the debian toolbox image?

Because I'm not able to reproduce the issue with those.

@nafiz1001
Copy link

nafiz1001 commented Mar 11, 2024

@nafiz1001 Are you using the latest distrobox version 1.7.0 and the debian toolbox image?

Because I'm not able to reproduce the issue with those.

I tried debian toolbox image, same result

nafiz@thinkbook:~$ distrobox-create -i quay.io/toolbx-images/debian-toolbox:12 --unshare-netns
Creating 'debian-toolbox-12' using image quay.io/toolbx-images/debian-toolbox:12	 [ OK ]
Distrobox 'debian-toolbox-12' successfully created.
To enter, run:

distrobox enter debian-toolbox-12

nafiz@thinkbook:~$ distrobox enter debian-toolbox-12
Starting container...                   	 [ OK ]
Installing basic packages...            	 [ OK ]
Setting up devpts mounts...             	 [ OK ]
Setting up read-only mounts...          	 [ OK ]
Setting up read-write mounts...         	 [ OK ]
Setting up host's sockets integration...	 [ OK ]
Integrating host's themes, icons, fonts...	 [ OK ]
Setting up package manager exceptions...	 [ OK ]
Setting up package manager hooks...     	 [ OK ]
Setting up dpkg exceptions...           	 [ OK ]
Setting up apt hooks...                 	 [ OK ]
Setting up distrobox profile...         	 [ OK ]
Setting up sudo...                      	 [ OK ]
Setting up user groups...               	 [ OK ]
Setting up kerberos integration...      	 [ OK ]
Setting up user's group list...         	 [ OK ]
Setting up existing user...             	 [ OK ]
Setting up user home...                 	 [ OK ]
Ensuring user's access...               	 [ OK ]

Container Setup Complete!
bash: go: command not found
nafiz@debian-toolbox-12:~$ ping google.com
PING google.com (172.217.13.174) 56(84) bytes of data.
^C
--- google.com ping statistics ---
11 packets transmitted, 0 received, 100% packet loss, time 10219ms

nafiz@debian-toolbox-12:~$ exit
logout
nafiz@thinkbook:~$ distrobox-list 
ID           | NAME                 | STATUS             | IMAGE                         
e49bb5d6b107 | debian-toolbox-12    | Up 55 seconds ago  | quay.io/toolbx-images/debian-toolbox:12
nafiz@thinkbook:~$ distrobox --version
distrobox: 1.7.0

@89luca89
Copy link
Owner

Still, I'm unable to reproduce

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants