There's no hard deadline for you to return to the US. There are some consequences, however, beginning at 180 days, at which point you are to be processed at the border as an "applicant for admission," which will usually have little practical impact on the process.
After a year, your green card is no longer valid for admission to the US. This doesn't mean that you lose your LPR status, and the green card remains valid for other purposes. It just means that you should get a returning resident visa (unless you have a re-entry permit, which you would have to have acquired before leaving the US, so I assume you don't have one).
There are ways to get into the US without a returning resident visa -- in particular, an airline isn't going to refuse to fly you to the US, because they won't know that you've been away for more than a year.
Your LPR status remains until there is a formal finding that you have abandoned your residence in the US. This can be a result of your voluntarily relinquishing it or of an administrative or judicial action. In general, it's probably safe to say, the longer you're away, the more likely the immigration officer is to look into the possibility of abandonment.
If you are absent for more than six months, you may also delay your eligibility to naturalize because this absence would disrupt "continuity of residence."
A good starting point is the USCIS page International Travel as a Permanent Resident, which has more information about these matters as well as links to more detailed descriptions of some of them.
Since this is https://law.stackexchange.com/, I suppose I should add some citations.
The 180-day threshold is found in 8 USC 1101(a)(13)(c).
The one-year threshold is at 8 CFR 211.1(a)(2).
Residence requirements for naturalization are regulated at 8 CFR 316.5. It should be stressed that failing to meet these requirements does not by itself put your LPR status at risk; it only affects your ability to qualify for naturalization.