The fact that it is multiple ports and multiple sound cards is odd. With that being the case, its almost certanly got to be a pinch point on the wire or a strain point of some sort. How do you put away your headphones when you are done with them? do you hang them by their cord? are you frequintly plugging into the socket and removing the plug? if so, do you grasp the barrel or do you pull it by the wire? What gauge headphone wire are we talking here? have you tried them on a completely different socket and see if the issue is actually with the headphones or with the PC? If it were just the one sound card i'd say the balance slider in audio settings somehow got set all the way to right or left (generally under mixer settings in windows, one slider controlls most output devices)
A stereo headphone jack is generally composed of three parts. A tip, a ring, and a sleave, or TRS. Those three contact poihnts are what lets the plug recieve a different signal for left and right. As polderan mentioned, if you pull a stereo plug out far enough and position it just right, the ring contact point will bridge to the tip and basically create a mono signal in both ears. GFenerally the right ear is going to be wired to the portion of the plug that goes furthest into the socket, and if there is any possibility of damage, it will be the one to fail, and its usually an indication of socket wear rather than a damaged cord. On the other hand, cords do nwear easily, especially if the wire is very light gauge, and if it is passing by your computer in such a manner that there is a pinch point. if the headphones are older, you may wnat to replace them. If you plug them in and out frequently, you may also want to replace them.
If it was just the one port, I'd say its the socket itself. Dust can cause it, so you'll want to blow the socket out with compressed air. It's usually wear, and the only way to really fix it is to replace the socket. There are some workarounds involving aluminum foil wrap on the plug, or opening up the case and bending the contact springs down further, but generally if you are oipening up the case you should replace the component anyways. If it is a laptop, sometimes they are smart enough to put that socket on a daughter board that can be replaced without soldering or replacing the entire motherboard. that really depends on the manufacturer though.