I understand that a mezuzah is required on the doors of rooms that are permanent dwellings.
Hotel rooms and cruise ship cabins are rented to different people. Does the passenger or hotel guest need to place a mezuzah on the door?
I assume that the owner of the hotel / the boat is not Jewish. I assume also that you asked for outside of Erets Israel. l
Shulchan Aruch YD 286, 1 & 22-23:
הגה: ודוקא כשבית השותפים ישראלים. אבל בית של ישראל ועובד כוכבים -- פטור ממזוזה (מרדכי ספ"ק דעבודת כובבים). וכן חצרות של עיירות שמקצת עובדי כוכבים דרים שם -- פטורים ממזוזה (חידושי אגודה פ"ק דיומא)
The shared appartement which is obligated to have a Mezuza is when all the members are Jews. But an appartement of Jews and non Jewish people is exempt from Mezuzah. Likewise a courtyards in which non Jews and Jews dwell are exempted from Mezuza.
השוכר בית מאינו יהודי -- חייב במזוזה.
One who is renting an appartment from a non Jew is obligated to have a Mezuza.
If I understand right the reason is that the Mezuza can put him at risk because NJ can believe that he makes Magic things So, a visible (in a public place) Mezuza is not necessary because of risk of antisemite aggression and because of fear of vandalism of the kaddosh parchment.
RI stated that even after 30 days, one who is renting a house from a NJ is exempted from Mezuza.
Is there a minimal amount of time that defines "permanent dwelling" halachically?
The Tur, and the Smag, supported by the Yerushalmi obligated after__30 days__ for a non visible Mezuza.. And Shulchan followed them.
But all this stringency for 30 days is still not a proof that someone who books an hotel room for 30 days need Mezuza.
What if a person is on business for 6 months and stays in the same hotel room or ship cabin?
Rabenu Yerucham (and Shulchan Aruch after him) stated that if the room is only for him or for a group of Jews and he booked it for a month he has a duty of Mezuza after 30 days.
But to book a room for less than 30 days is not similar to renting an apartment, the proof is in sayif 22, renting an apartment in Erets Israel is obligated immediately but booking a room after 30 days only.