I am very new to regression analysis. I have a dependent variable and 9 independent variables. I want to build the best possible model from them, and I don't know when to log transfrom a variable.
"Best possible model" is not well defined.
Whether you should log transform a variable depends on both statistical and substantive considerations. If the substantive reasons aren't met then it may be best to use a different regression method (but maybe not).
First, you can only take logs of variables that are always positive.
Second, you take logs of a variable when the relationships to that variable are multiplicative rather than additive. For example, money amounts are often logged. If your dependent variable is, say, income, then, in some sense, doubling of income rather than adding a fixed amount is what is important. E.g. if you make \$10,000 and get a \$3,000 raise, it's huge. If you make \$250,000 a year and get a \$3,000 raise, it isn't huge.
Statistically, logs are taken to remove right skewness. But "regular" OLS regression makes assumptions about the distribution of the residuals, not the variables themselves.