Can you have a disconet on the outside of a building and one inside. Shouldnt these be grouped together either both outside or both inside. The one outside feeds a seperate building?
Yes the disc outside does disc. power from the other buildiling along with the solar I thought disc. had to be grouped. The disc. are not fed from one another. They tied on ahead of main so they dont overload busbar in panel, but they put the disc. outside instead of next to the other one inside.
The service disconnects disconnecting the building from the service (utility in your case) do have to be grouped at one location. In other words when you go to the service disconnect location and open the service disconnects in a building all ungrounded conductors must be disconnected from the service for the building you are in. (mindful there are always exceptions to the general rule). None of the exceptions apply in your case. So all of the service disconnects for the dwelling have to be grouped in one location. In your case that is what happens. There is only one service disconnect for the dwelling in your case.
230.40 addresses you concern more than grouping of service disconnects. One service drop or lateral is only allowed to supply one set of service entrances. You have two sets of service entrance being supplied by one service. I believe you implied this was a single family dwelling and if that is the case the installation is code compliant. In fact because it is a single family dwelling the disconnect outside is not required. The second building is however required to have a service disconnect.
If this installation was not a single family dwelling then you would have to have the service disconnects grouped in one location.