You'll want to add either addnode=<ipaddress> or connect=<ipaddress> to the bitcoin.conf of the node that is not working, where <ipaddress> equals the 127.0.0.1
These can also be command line flags (e.g., bitcoind -connect=127.0.0.1).
The difference between addnode and connect is explained like this (attributed to 'Noodle' on Freenode):
Quick Primer on addnode vs connect
Let's say for instance you use addnode=4.2.2.4
addnode will connect you to and tell you about the nodes connected to 4.2.2.4. In addition it will tellthe other nodes connected to it that you exist so they can connect to you.
connect will not do the above when you 'connect' to it.
It will only connect you to 4.2.2.4 and no one else
So if you're behind a firewall, or have other problems
finding nodes, add some using 'addnode'.
If you want to stay private, use 'connect' to only connect to "trusted" nodes.
If you run multiple nodes on a LAN, there's no need for
all of them to open lots of connections. Instead 'connect' them all to one node that is port forwarded and has lots of connections.