What is maximal entropy? I am confused about the meaning of maximal entropy. Is it maximal when all particles have same velocity or when there is a gaussian distribution of velocities? In simple words does the system tend to a gaussian distribution or identical energy among particles?
 A: Maximum entropy means maximum number of accessible microstates (e.g. particle positions, velocities, available energy states) for a given macrostate (e.g. $V,T$). So you often see (for a canonical ensemble) that $S=S(V,T)$. This actually means that the value of $S$ for this particular $V,T$ combo is such that the number of possible microstates (e.g. particle velocities) is maximized. It turns out, that for a given temperature, the velocity distribution that maximizes the number of microstates is the Maxwell Boltzmann distribution.
A: You should had specified better what is the system  whose entropy should be maximum.
From what you write I can guess that you are considering a classical system (quantum systems would require a different approach).
Moreover, you should state explicitly what are the external conditions controlling  your system.
I would assume that the physical system is insulated, i.e. no variation of energy ($E$), volume or number of particles is allowed. Under such condition, the maximal entropy would correspond to a uniform probability in the accessible phase space.
Indeed, if we start with the most general expression for the Boltzmann-Gibbs entropy:
$$
S = -k_B \sum_i p_i \log p_i,
$$
where $p_i$ is the probability of the $i-$th volume element of phase space, and $k_B$ the Boltzmann's constant, it is straightforward to verify that maximum of $S$ with respect to $p_i$, with the obvious constraint that $\sum_i p_i=1$, implies $p_i = \mathrm{constant}$ over the accessible phase space, i.e. for all the states which have the energy $E$. 
Equal probability of the microstates at constant total energy $E$ implies:


*

*that for a finite system the velocity distribution function is not exactly a Maxwellian (although it is a good approximation even for a few hundreds particles). A straightforward simple argument for this conclusion is that a Maxwellian distribution would allow arbitrary large velocities (although with low probability), while in a system where energy is fixed, individual velocities are upper limited. Let's call this distribution a quasi-Maxwellian distribution.

*That any velocity distribution different from the quasi-Maxwellian should correspond to a lower value of $S$.

