I2c pull-up on +5 problem

Hi, i am trying a sketch with 2 arduinos connected in i2c, it only works if i power both ardunos with a common +5 and ground, if i switch to separate +5 and common ground they don't talk anymore.
I have seen some examples that says to put a pull-up resistor between +5 and SCL SDA, but i am a little worried doing so, doing it wrong can do some harm to the arduinos?

I want to keep the +5 separated so i can make the 2 arduinos power down and reset each other in case of fail.

Are you sure you made a common GND? Because it should work that way.

PS You don't need separate 5V to be able to reset each other. You can just connect to the reset. Or more common, don't even use two Arduino's and use the WatchDog timer.

If they are connected and separately powered you have to take care never to drive any of the bus lines
HIGH (I2C is open collector so this should work). I suspect you don't have proper pullups on the bus,
use 10k's on one Arduino only to pull up. Weaker pull ups are prefered to avoid phantom-powering
via the I2C bus. However if the cables are long this might not work, then try 4k7.

Thanks, using Watchdog is not an option, the whole picture of this is much more complicated, but in two words i am sending some values to InitalState service via Json, sometimes while sending the Json data to the server the arduino gets corrupted and hangs, the Watchdog usually resets it, but one every 100-1000 hangs the Watchdog seems not able to properly reset and the arduino remains hanged until i turn it off.
It is a "rare" occurrence, like one in 1-2 weeks and i am not able to reproduce the error, so i really have no simple way of debugging it.
Moving the part of code that sends the Json to another arduino and controlling it via i2c is the only way i see to make the project stable, since i have no time/knowledge to fully debug it, since it partly seems as a problem of the lan problem of the customer, since the Json fails between 09-18h and usually works 18-09
During these working hours it can fail (and hang, but successfully set itself) 50-200 times a day, but once in 7-14days it can't recover after a reset.

Excuse me for the OT.

Alright, your project. But don't come whining when it doesn't work. Because "the arduino gets corrupted and hangs" is just a sign of you having a bug :wink: And the WD is ALWAYS able to reset the Arduino :slight_smile: I would not dare to make a ugly/buggy setup for a customer...

Back to the problem, try installing external pull ups.

How far apart are two Arduinos? Connected by what type of wire?