# Web server interview प्रश्नोत्तरं

Source: https://ravindrabagale.com/mr/aws/ch06-web-servers-nginx-and-apache/interview-questions.html
Language: mr (Marathi with English technical terms)

Q1. Nginx/Apache फरक?

Nginx asynchronous event-driven; static/proxy कामात कार्यक्षम. Apache MPM आणि modules निवड देतो; .htaccess support आहे. प्रत्यक्ष performance workload/config वर अवलंबून.

Q2. Reverse proxy?

Client request backend app — उदा. 127.0.0.1:3000 — कडे पाठवून response आणणारा server. TLS termination, caching, load balancing आणि access controls देऊ शकतो.

Q3. Nginx config test?

sudo nginx -t; pass झाल्यावर sudo service nginx reload.

Q4. 403/404/502?

403 access denied; permissions/SELinux/index policy. 404 resource not found; path/root. 502 proxy ला योग्य upstream response मिळाला नाही; app/port/socket तपासा.

Q5. SELinux label fix?

SELinux mandatory access control. Default path वर sudo restorecon -Rv /var/www/site; custom path साठी आधी योग्य semanage fcontext rule.

Q6. .htaccess?

Apache per-directory config; overrides enabled असल्यास request processing मध्ये तपासतो. Nginx ते वाचत नाही; central config मध्ये equivalent rules लिहावे लागतात.

रवींद्र बागले यांची tip

Command सोबत path आणि distro सांगा. “Apache config” एवढ्यापेक्षा कोणत्या OS वर कोणती file ते स्पष्ट करा.
