It was a rewrite of Minix.
Tanenbaum created Minix but his limitation (education only/the source codes were only available to university students) killed it.
Linux caught on fire because it gave free source codes, free distribution, you can make money with it. There is almost no limitation except if you change it you have to give your codes back.
At the beginning, it was just people who want to learn(OSes) + hobbyists. Then companies figured out how to make money with it. Then the rest is history.
If they could not monetize Linux, I don't think it's here today.
BTW: Tanenbaum later tried Linux way but it's too little, too late.