Ping ubuntu from windows

Сеть между Windows и Linux: нет пинга

Есть следующая сеть:
Компьютер, настроенный под рутер. Назовём его рутером. На нём установлен debian linux.
Компьютер, который хочется подключить к нему и устроить LAN из 2х компов.

Когда на LAN компьютере запускаю linux (Fedora), то рутер пингуется и всё впорядке. Когда запускаю Win XP, то пинг пропадает (его нет даже при таймауте в 40 сек и размере пакета 1байт).
router IP — 192.168.0.1
router netmask — 255.255.255.0

WinXP IP — 192.168.0.2
netmask — 255.255.255.0
gateway — 192.168.0.1

Брендмауер в винде выключен.

В чём может быть проблема?

Добавлено через 1 час 37 минут
Заметил ещё такую особенность:
Если зайти в «Сетевые подключения», и в свойствах этого подключения нажать «Исправить», то появляется пинг на 2 пакета и потом снова пропадает. Причём на каждое исправить пинг на 2 пакета стабильно появляется.
Причём исправление ломается на очистке DNS кэша (это кажется не играет никакой роли), и проходит 3 стадии:
Очистка ARP-кэша, очистка NetBT, обновление NetBT.
Может быть ARP-кэш засоряется какой-нибудь гадость? Или дело в NetBT?

Как настроить сеть между компьютерами на Windows XP и Windows 2000 Prof?
Ne mogu naladiti seti . Pomogite! Konfiguratsia takai: Notebook s XP s USB kartoi i desktop.

Сильно тормозит сеть между Windows XP и Windows 7. Как обнаружить причину?
Есть сетка wi-fi. В сети три компа. Два из них на Win7 и один на WinXP. Сеть по обычной схеме -.

Нет общего доступа между Windows XP и Windows 2008R2\Windows 7
Прощу помощи разобраться в проблеме: ПК с установленной windows XP не может открыть папку общего.

Настройка Open VPN — нет пинга, подключение есть
Помогите разобраться в чем тут может быть дело. Подключение есть,а вот пинга с клиента на сервер.

Просто ping -t -w 100 192.168.0.1
Сейчас попробую arping

Выяснил:
если удалить arp кэш у винды, то пинг появляется на 2 пакета.

Добавлено через 13 минут
Если делать arping 192.168.0.2 -I eth1 на рутере, то пинг идёт нормально без сбоев. В этот момент пинг с виндовской машины становиться лучше (50% сбоев).
Неправильно настроены routing tables на рутере? (Но с линуксом на клиентской машине проблем ведь нет)

Добавлено через 11 минут
Если пинговать arping’ом с виндовской машины — то тоже всё впорядке, пинг arping идёт 100%. Пока идёт arping с виндовской машины простой пинг тоже проходит на 100%

Добавлено через 18 часов 13 минут
Перепроверил тублицы роутинга у рутера и сервисы у винды.
Не обнаружил нечего необычного. Непонимаю в чём может быть дело

Добавлено через 1 час 51 минуту
Посмотрел что происходит в сети через сниффер. Вот 2 пакета в качестве примера (в оффтоп убрано лишнее, жирным выделенно подозрительное).
Пакет от рутера:
ARP request

Читайте также:  Huawei modem linux ubuntu

HW type: Ethernet (0x0001)
Protocol type: IP (0x0800)
HW size: 6
Protocol size: 4
Opcode: request (0x0001)
[Is gratuitous: False]

Sender MAC address: 00:00:00_00:00:12 (00:00:00:00:00:12)
Sender IP address: 127.0.0.1 (127.0.0.1)
Target MAC address: 00:00:00_00:00:00 (00:00:00:00:00:00)
Target IP address: 192.168.0.2 (192.168.0.2)

Снифер выдаёт следующее инфо об этом пакете: «Who has 192.168.0.2? Tell 127.0.0.1»

Пакет от винды:
ARP reply:

HW type: Ethernet (0x0001)
Protocol type: IP (0x0800)
HW size: 6
Protocol size: 4
Opcode: reply (0x0002)
[Is gratuitous: False]

Sender MAC address: AsustekC_79:86:ca (00:1b:fc:79:86:ca)
Sender IP address: 192.168.0.2 (192.168.0.2)
Target MAC address: 00:00:00_00:00:10 (00:00:00:00:00:10)
Target IP address: 127.0.0.1 (127.0.0.1)

Снифер выдаёт инфо на этот пакет: «192.168.0.2 is at 00:1b:fc:79:86:ca (duplicate use of 127.0.0.1 detected)»

Странно что 127.0.0.1 учавствует в arp. Странно что у него постоянно меняется mac адресс.

Если очестить arp кэш, то последовательность пакетов в сети такая:

1. «Who has 192.168.0.1? Tell 127.0.0.1» — это запрос к рутеру
2. «192.168.0.1 is at 00:1b:fc:79:86:ca» -ответ от рутера
3. Echo (ping) request
4. Echo (ping) reply
5. Echo (ping) request
6. Echo (ping) reply
7 «Who has 192.168.0.2? Tell 127.0.0.1 (duplicate use of 127.0.0.1 detected)»
8.»192.168.0.2 is at 00:1b:fc:79:86:ca (duplicate use of 127.0.0.1 detected)»
9. DNS запрос антивируса
10. DNS ответ антивирусу
Всё.

Примечательно что в п.1, п7 и п.8 используется 3 разных мак адреса (причём все они какие-то странные типа 00:00:00:00:00:53)
+/- 3 к последнему числу.

Can’t ping from Windows to Linux server

Basically, I can ping from my Linux server to Windows (when I disable the firewall), but I can’t ping from Windows to Linux, whether I disable the ufw-firewall or not. It just doesn’t reach it. My Ubuntu uses a Network Bridged Adapter, as well.

Linux server’s IP:

Windows IP (Wi-Fi):

Because of this, I think, I cannot connect to the linux server using SSH as well. Firewall can’t be the issue, because I disabled both of them.

I’ve said this in the comment section below, but might as well repeat it here. No, SSH does not work. It gives the famous error: «Network error: Connection timed out», and I still haven’t been able to fix that problem.

Yes, my Ubuntu host is on a Virtual Machine (VirtualBox). I’m just trying to connect my Ubuntu server (which is on a VM), to my Windows host, through SSH. But that doesn’t work. Since that didn’t work, I tried to ping the two, and one of two was successful, which is strange. If it’s the Network Bridge Adapter which is causing a problem, what do you suggest I take? And also, I HAVE done SSH before, and it worked. Only now, after a couple of months, I’m trying to do SSH again, and now it’s failing, for some weird reason. Should I try and change the IP of my Ubuntu?

It’s an Ubuntu Server. Here are the two relevant config-files of my server:

1 Answer 1

We need a little more information on your network setup to answer your question fully, but I believe I know at least what is causing the issue.

Читайте также:  Перегрузка диска 100 windows 10

1) Both the Windows and Linux computers are supposed to be on the same local network.

2) The Linux server is not a virtual machine.

3) You are using bridged connections on your Windows machine to share its wireless connection to the Linux server through ethernet. (You bridged Wireless and Ethernet in Windows to get a connection to Linux.)

Then the problem is likely your network bridge. Your router assigned the local IP 192.168.0.110 to the Windows machine, and this is a common subnet for local networks.

The issue is that your Linux server has the IP of 10.88.77.111, which is an entirely different subnet. This means it likely did not receive an address from your router properly, and because of this Windows cannot ping the Linux server.

I would remove the network bridge, check all of your settings, and try to create it again. Did you change any settings from default when creating the bridge, such as setting static addresses under the «Internet Protocol Version 4 (TCP/IPv4)» properties, for example?

Edit:

Since your Linux server is a virtual machine, the above information does not apply to your setup.

When you originally setup the virtual machine, did you change any of the network settings?

Edit #2:

Wait a second, that address you have your server set to looks very similar to the address VirtualBox assigns when the network settings are in NAT mode. Are you sure it is in bridged mode, like this for example:

If it is in bridged mode, and not NAT, then set the /etc/network/interfaces file to automatically retrieve an IP address. It will likely look more like the Windows one. If the automatic address it gives you works, then configure the static IP address to be what it gave you automatically.

How do I ping the Ubuntu host system from a Windows guest in VirtualBox?

I connected to a wireless point and use «ifconfig» but I don’t see any IP in eth0. Where’s my IP address? Sorry if this is a silly question. 🙂

I want to use «ping» in Virtualbox Windows 7 guest. Which IP should I type in that machine?

1 Answer 1

The easiest way to get this is to just open up your connection information from the appindicator, like this:

That brings up your local IP address. Note that this isn’t your IP address on the Internet, just your local address. You can always go to whatismyip.com for an easy way to see it.

In your screenshot, eth0 is an Ethernet connection, and wlan0 is your wireless connection. To get your IP address in the Windows virtual machine, try typing ipconfig/all at a command prompt (Start/Accessories/Run/type ‘CMD’, and looking for your default gateway there:

In this example, my guest sees the Ubuntu host as 10.0.2.2

It may be that the VM sees it as a wired connection, even on a laptop with the host using wifi.

Can’t ping my ubuntu pc from Windows 7 pc

I tried tips from this link and disabled my ufw without success. Ubuntu machine not responding to ping from Windows machine on same network

Читайте также:  Windows 10 insider preview build iso

When i listen for pings from my ubuntu, I receive the ping as you can see here:

Ubuntu pinging Windows 7:

Windows pinging Ubuntu:

sudo iptables —list

With purged ufw, stopped fail2ban and stopped ssh

1 Answer 1

Have you tried to do a:

test again and if that works, a:

again and if that works too, keep it that way.

Looking at your latest output, rule #8 is the culprit. Please before executing the following command, verify that the 8th line on your current output to iptables —list starts with a DROP.

OK? Verified. … Double verified. … Sure.

Then do this command: iptables -D INPUT 8

Not the answer you’re looking for? Browse other questions tagged windows ping or ask your own question.

Linked

Hot Network Questions

Subscribe to RSS

To subscribe to this RSS feed, copy and paste this URL into your RSS reader.

site design / logo © 2021 Stack Exchange Inc; user contributions licensed under cc by-sa. rev 2021.4.16.39093

By clicking “Accept all cookies”, you agree Stack Exchange can store cookies on your device and disclose information in accordance with our Cookie Policy.

Ping Ubuntu by hostname in a Windows machine

I installed Ubuntu 12.04 on a Virtual Machine (Virtualbox). The network adapter is attached using bridged adapter.

I can ping the guest OS by IP but I can’t ping it via hostname.

I already installed Samba and winbind. I also edited /etc/nsswitch.conf to and ‘wins’.

Does the settings takes time to take into effect? What other things can I try to be able to ping the Ubuntu OS by hostname?

4 Answers 4

Not sure why Ubuntu is different but this works with debian:

Install debian using bridged networking

As soon as Samba is installed and running the guest machine can be pinged by hostname. I’m using a Windows 7 host and a Debian 7 LXDE guest.

You need name resolution. Either static (lmhosts, hosts) or dynamic (wins, dns). See this short ancient write-up I did years ago The lmhosts and hosts files for a quick overview.

You didn’t mention which version of Windows you’re running but do note that a «homegroup» is not a workgroup (or a domain). And a «homegroup» is only valid between Windows 7 (and I presume 8) systems so it is quite limiting and should be avoided.

Winbind allows Samba to authenticate via an external PDC or AD and should not be confused with WINS. To use WINS you need a WINS server (!). For Samba to act as the WINS server the smb.conf global section needs a wins support = yes entry, plus do not use a wins server = entry (this entry is for directing Samba to use another WINS server and not be one itself).

Other systems need to register with the WINS database in order for it to be effective, easily accomplished via DHCP but can be manually configured as well.

Оцените статью