Hi @vikash,
Are you trying to connect both PCs over a cross over ethernet connection?
If yes, did you set a static IP address on both machine’s ethernet adapter properties?
For assistance, please check the instruction on this link https://helpdeskgeek.com/networking/connect-two-computers-using-a-crossover-cable/.