Should I contact the journal after "with editor" for two months? I submitted a paper to an Elsevier journal two months ago. I checked the status today and it was "with editor". I understand the reviewing process may take a while, but apparently it is not under review yet. I did a bit research and found that most papers in the journal are accepted less than 6 months. I am wondering if it is appropriate for me to send inquiry message to the editor in this case? Or a more general question is how long should I wait till sending them inquiry/reminder messages. Thanks.
You can always send a message to an editor to enquire about the status of your manuscript. But, you need to consider a few basic points.

First, try to assess how the journal operates, for example what time frames are usually met by people submitting work to the journal. Try also to see what is considered the norm in your field (assuming this journal is in that field). Since the way journals operate varies between both fields and amongst the journals themselves, you need to assess what is a reasonable time. 

Second, Try to see if you can figure out what this message "with the editor" means. I would interpret it as not having been sent out for review yet. If that is true then it seems like posing a question would be timely. If the message indicates the paper may also be under review or possibly even back after review for the editor to evaluate, then two months is certainly not too long. So, understanding the process stages and how the messages relate to these may help you decide whether a request is timely or not.

Editors, should not mind responding to brief questions of this sort but if it is clear from their point that the request is clearly premature, it will add to the stress. In other words, an assessment from your side of the normal waiting time along with an appropriate question is a good ground for the communication. Such an assessment can be made by asking your peers and others who have submitted to the journal. You can also kindly ask the editor to provide some insights into the time frame of the review process. It is after all not uncommon that authors may be more or less ready to handle revisions at different times and knowing what to expect is therefore useful.