Since you are mostly asking an opinion question I will give mine. Your best bet is to get out of this real estate deal ASAP. You do not have the money or the margin to make this work and it could very likely bankrupt you. I am assuming that bankruptcy is not your goal.
The next best option is another that you did not present: Work like a crazy person and get this 30k paid off. Get a second and/or third job, and be done with this in 9 months, no more than one year. Only do this if you really want to own rental real estate. Your work won't be over, you will then have the mortgage on both your home and the rental to contend with, but at least you won't be on the verge of drowning.
Then come your options, both are horrible in my opinion. On the one hand you put your primary residence at risk of foreclosure and on the other you run the risk of borrowing money from the government at ~30% interest rate or more. Both loans are callable and can be due in full in a short term. Did you realize that? Does that sound pleasant?
All it takes is a fairly common series of events that will lead you to telling "tales of woe". Deadbeat tenants do exist, and might very well also destroy you property. Some may pay rent, but rebuild their motorcycle in the living room. Home equity loans can be called, and people change jobs (either by choice or not).
So if you use a good portion of this money to first service the mortgage and later repair the rental after a dead beat tenant and then you are laid off. You will owe your tax rate plus a 10% penalty on the balance of the 401K loan. Not fun.
If you took a hard look at the economics, including risk, of renting it is unlikely that it can be very profitable when one has a mortgage for the full amount.