I am baking a rifle in Substance Painter which consist of 40 small and big part using one UV map. Some object have very closed places which result in overlapping AO so I tried 0.005 max frontal distance. But when I change it other objects get weird baking. Is there anyway to bake all the object individually with different max frontal distance using single UV map.
The Matching By Name feature was made exactly for you use case: avoid objects bleeding on each other during the baking process. With it you can isolate low and high poly meshes in groups. This way you don't need to fiddle with the ray distance.
Sorry if I didn't explained the problem correctly. I am already using by mesh name. I want to get rid of this small closed area where normal and ao is baking on each other. Someone told me to bake 2 AO and normals and combine them in photoshop. But I can't combine them with exact values. For example I put two AO maps in photoshop and changed one to multiply. It mix together but the result was a little grey. After that I used level to but I can't find a certain value to make it as original bake.
I don't think there is an easy solution here unfortunately. I would advise to split your object further so that you can use matching by name on this component too, but I suppose it's not always possible in your case.
If you want to go with baking two verisons and mixing them together, you can do that in Painter itself. You will need to bake your first version, export it and re-import it under another name, then bake the second version. You can then blend them in the layer stack (by changing the mixing mode in the Texture Set settings). For the AO you likely don't want to mix them with "multiply", otherwise dark areas will get double intensity. Just using the "normal" blending to go over specific areas will work better.