Private LAN with out any Internet connection

i am trying to setup Nextcloud hub on LAN with out internet connection. the problem is nextcloud route through internet every time even after changing my DNS setting pls help

I think it is much easier to install Nextcloud with internet connection. Also there is a difference between the internet can access your nextcloud (e.g. router port forwarding) and the nextcloud can access the internet (e.g. download patches, apps, …)
Please write why you have no internet to install nextcloud but internet to write this post.

i work as an IT teacher in a remote school, i am currently using internet connection in an internet cafe 400 km from the school once i finishes this research i will go back to test it and come back in a month or two if i have problems.
the school has good LAN infrastructure to all class rooms and offices with WiFi reaching 2 km radius from our main server.i want to use Next cloud create centralized communication using text ,audio,video and office doc editing.

Thank you for the more detailled information. Can you more expalin your above quoted problem? How do you access your school? You and the school must have internet connection. Why does your nextcloud server have no internet connection?

i as said before the school does not have internet concatenation, my plan is to host next cloud on local server and use it with in my LAN

Ok i think you have installed nextcloud correctly with e.g. apache2, mariadb, nextcloud, …

Nextcloud is practically only a webserver. In a private lan you uses normally a dns server and the dns looks to a private ip address e.g. 192.168.x.x

If your routing and dns is correct the client in the network direct access the webserver (nextcloud). Do you use other webserver or servers in your network? Can you compare the entries for ip and dns? Have you checked the routing tables on your nextcloud server? Can you access your nextcloud server with a ssh-client (e.g. putty) with the protocol ssh?

Please read for further nextcloud offline upgrades.
Upgrade manually — Nextcloud latest Administration Manual latest documentation

i have another Digital Library running on the same server

i will setup dedicated server for it .

Ok if you have another Digital Library running on the same server i think you uses a virtual host or another port that it works. If the nextcloud server tries to contact the internet please post logs. Thanks.

will do see you in month

Read this: Disable update-check

'updatechecker' => false,
'has_internet_connection' => false,

Check if Nextcloud is up-to-date and shows a notification if a new version is available.
Is Nextcloud connected to the Internet or running in a closed network?

https://docs.nextcloud.com/server/19/admin_manual/configuration_server/config_sample_php_parameters.html