When were you divorced? If divorced before the end of 2019, then you file as single and don't need your ex-husband's SSN. If you are flling Married Filing Separately because you were still married at the end of 2019, do you have a prior year tax return you can look at to find his SSN? Can you get a transcript of a prior year return from the IRS to find it? https://www.irs.gov/individuals/get-transcript
If you can't get it in any way, you will have to print and mail your Married Filing Separately tax return to get it accepted since an efiled return requires the other spouses SSN to be entered.
@Texas Roger Just to make sure I'm understanding correctly - I could mail in a printed copy, without having his social on it, and they will still accept it?