I have a headless mini computer with an Ethernet port, a Mac with a USB (not C) port, and a USB to Ethernet adaptor.

The mini computer is running standard CentOS Linux, and the eth interface is set to DHCP. The moment I connect the mini computer to a router via an Ethernet cable, it has access to the internet without any configuration.

The USB to Ethernet adaptor for my mac is also functional. I can connect it directly to the router and access the internet without configuration.

I would like to SSH into my mini computer over Ethernet, without needing the screen and keyboard, nor the intermediate router. However, I'm not getting any connectivity.

Do I need a cross-over Ethernet cable?

I know this is a very broad and ambigous question, but any pointers to what I could learn or investigate more about would be helpful.

closed as too broad by DavidPostill Jun 3 '18 at 11:21

Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • You should provide the make and models of the Ethernet cards used. With that information an answer might be possible. In any case you could just buy a crossover cable and test it yourself. – DavidPostill Jun 3 '18 at 11:22

You are very unlikely to need a cross-over cable these days. Most ethernet ports are 'smart' & can auto-switch if cross-over is needed.

At the moment, both machines are expecting to find a DHCP server to tell them 'who to be'. As neither machine is serving DHCP, this will lead to both machines setting up a private, essentially non-routable address in the range 169.254.x.x
This should, in theory, work - but as it doesn't appear to be, then...

The first step is to remove DHCP & set them manually.

Set one machine to & the other to
Gateway is strictly unimportant, as there's nowhere for them to go, but gateway & a subnet default of should work.

They are then on the same, routable, subnet & ought to be able to find each other.

On the Mac you can do this via the Location: drop menu, in Prefs > Network > so you can in future switch on the fly without needing to reconfigure. On CentOS, idk how this would be achieved.

  • To add, 1) Gigabit Ethernet ports are practically guaranteed to have auto-crossover; 2) Gateway can be left empty; 3) Subnet mask is still somewhat important (I don't think Windows has a special case for direct connections), but any value is fine as long as it covers both hosts' addresses. – grawity Jun 3 '18 at 8:06
  • 5
    And honestly, 169.254.x.x addresses would work just fine for this purpose. Non-routable doesn't mean non-usable. – grawity Jun 3 '18 at 8:07
  • In theory, absolutely; just that as it's not working using self-assigned addresses in practise, it seemed simpler to manually set an address. I was unsure about Gateway being empty; potential for the setup page to refuse 'no data', but picking one manually I didn't think would hurt anything. – Tetsujin Jun 3 '18 at 8:14
  • 1
    If you're only communicating between two, directly connected computers, APIPA/Local-Link addresses will work fine and gateway need not be set. It seems more likely to me that they're using older hardware that doesn't 'auto-switch' to cross-over mode. – 3D1T0R Jun 3 '18 at 8:17

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