Currently mysql.max_persistent and mysql.max_links are set to -1 which means unlimited
to optimize mysql, should i keep this unlimited or is it good to limit this? If i have to limit it, what is the best value that I can put there?
The answer is: it depends. IMHO, I believe that you shouldn't have these unlimited (unless you have complete control over the server, and thus you can be 100% sure that nobody will abuse your DB, not even a misbehaving application), as you risk exhausting your server resources.
You should calculate these in function of your server size, other mysql parameters (mainly, memory related), and the rest of things that the server have to do.
Because that can be a challenging task, there are people that runs mysql in a separate node (hardware or virtual, but with RAM reservation, like KVM), this is specially true in if you have several different services running, like: tomcat, apache, mail, ldap. If you have mix of MyISAM and InnoDB tables, you have to choose the parameters carefully, or risk impacting performance of either of them.
If there is a script that uses pconnect, would it be wiser to set the max persistent connection to 100? or should it be lower?
How complex are the queries?, how big the results?, how much ram do you have?, how much CPU?, how many parallel connections do you have to attend?, what mix of tables do you have (InnoDB, MyISAM)?, how big are the DBs for each of these?
Anyway, db optimization is not a simple task, but you can have a "good enough" approximation.