Solved --- How to boost voltage from 22 to 25-26 volts?

I have an old solar panel which outputs about 22 volts, and four used batteries which are rated
24 V. Any idea of how to boost the voltage to charge the batteries? I think I will need at least
two volts difference.

Throw 2x AA batteries into the mix, lol.

I think an op amp might do the trick for you. I hear they can up the voltage by 2 volts but it would probably be a trade off and drop your amps so watch out, charging times will probably go down slightly.

A step-up DC-DC converter, or a buck boost converter.

Something like this, step up dc dc 150w for sale | eBay

I decided to use DC to DC converter.
Thank you for responding to my question.
Les

If your panel puts out 22V open circuit then its probably designed to charge a 12v battery. The most
efficient operating point is a lot lower than the open circuit voltage. You panel's max output power
is likely to be at about 15V, about right to charge lead-acid 12V battery through a series diode (13.8V
nominal charging voltage)

Trying to power a standard DC-DC converter from a current source (solar panels are current sources)
may not work - I'd be wary of trying this.

I have a bunch of 24 V batteries and the panel I mentioned before.
I am trying to find a way to charge the batteries using hardware
I already have. Would charging these batteries to 12 V do me any
good? I don't really need 24 volts and 12 V would be OK.

No, that won't work. Use them with 24V or buy new batteries.

As I said, trade your amps for volts. From what I understand, this will take longer to charge but still get the results your looking for. You probably need 25.8 volts and need to connect in parallel.