It’s not permanent, but it last a damn good while. Seems to vary, not sure of he maximum time possible. Cough medicine will suppress the symptoms but not cure it. Royal jelly will cure it as you said, and in more recent experimental builds the Arcana mod’s red potion has been changed to cure that. X3
For preventing one, as mentioned there’s the flu shot. Whereas gamma globulin shot seems to just boost your healthiness a lot, flu shot outright prevents a cold or flu for about a year. Getting your healthiness up (vitamin everyday is best) and having the Disease Resistant traits help, but sheer math means you’ll still catch it eventually. Wearing a gas mask 24/7 outright eliminates any chance of catching it.