Lab 3.4. Domain Review

Hi, i am new to kubernetes and trying to get a hang of it. Not sure what is really expected from this exercise (Lab 3.4. Domain Review):
- Use the build-review1.yaml file to create a non-working deployment. Fix the deployment such that both containers are running and in a READY state. The web server listens on port 80, and the proxy listens on port 8080.
- View the default page of the web server. When successful verify theGETactivity logs in the container log. The messageshould look something like the following. Your time and IP may be different.
- 192.168.124.0 - - [30/Jan/2020:03:30:31 +0000] "GET / HTTP/1.1" 200 612 "-" "curl/7.58.0" "-"
I am able to make both the pods running and ready by just changing the port to 8080 under the liveness and readiness probes as mentioned in build-review1.yaml file. Also i added port section for nginx container on 80 as mentioned above.
But in logs for both the containers i don't see the below line (its empty logs)
192.168.124.0 - - [30/Jan/2020:03:30:31 +0000] "GET / HTTP/1.1" 200 612 "-" "curl/7.58.0" "-"
not sure what is expected from this exercise? I understand ip will be different but i don't see anything for both container logs.
Thanks
Rishu
Comments
-
Hello,
Keep viewing the default page of the web server. Are you able to see the default nginx welcome page? Once you can see this, do you see a entry in the log showing the GET?
Regards,
Tim
0 -
Hi Tim, the missing part was i didn't try to curl to the nginx server and was checking the logs directly. i did curl -vk http://<
>:<> from the master node and after this i can see the logs getting updated..
thanks
Rishu0 -
where did you see the logs? @Rishu1977 All i saw the html for the nginx
0 -
Hi @ashdev,
You can revisit "Chapter 3 - Build" for an example on how to display container logs.
Regards,
-Chris1 -
Hi, I keep reading "chapter 3 - Build" but couldnt find how to display and configure logs...
0 -
Hi @zite,
You can find
kubectl logs
command usage examples on the Testing page in Chapter 3.Regards,
-Chris0 -
Hi, sorry if I'm wrong, but using LFD259-labs_V2023-05-31.pdf document, and cannot find 'kubectl logs' command on chapter 3. I can see the first occurrence of this command on chapter 5
0 -
Ok, I managed to get the logs
0 -
This is what I did.
ubuntu@cp:~/LFD259/MY_SOLUTIONS/s_03$ kubectl get pods -o wide NAME READY STATUS RESTARTS AGE IP NODE NOMINATED NODE READINESS GATES break2-7df45c9687-5g7sm 2/2 Running 0 12m 10.0.1.115 worker <none> <none> nginx-7b8bd4f85d-fg6f7 1/1 Running 1 (90m ago) 100m 10.0.1.35 worker <none> <none> registry-8596585bb9-nvqc4 1/1 Running 1 (90m ago) 100m 10.0.1.15 worker <none> <none>
curl my pod a few times
curl 10.0.1.115
ubuntu@cp:~/LFD259/MY_SOLUTIONS/s_03$ kubectl logs break2-7df45c9687-5g7sm Defaulted container "brokenapp" out of: brokenapp, goproxy /docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration /docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/ /docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh 10-listen-on-ipv6-by-default.sh: info: Getting the checksum of /etc/nginx/conf.d/default.conf 10-listen-on-ipv6-by-default.sh: info: Enabled listen on IPv6 in /etc/nginx/conf.d/default.conf /docker-entrypoint.sh: Sourcing /docker-entrypoint.d/15-local-resolvers.envsh /docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh /docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh /docker-entrypoint.sh: Configuration complete; ready for start up 2025/04/16 14:28:10 [notice] 1#1: using the "epoll" event method 2025/04/16 14:28:10 [notice] 1#1: nginx/1.27.4 2025/04/16 14:28:10 [notice] 1#1: built by gcc 12.2.0 (Debian 12.2.0-14) 2025/04/16 14:28:10 [notice] 1#1: OS: Linux 6.8.0-1026-aws 2025/04/16 14:28:10 [notice] 1#1: getrlimit(RLIMIT_NOFILE): 1048576:1048576 2025/04/16 14:28:10 [notice] 1#1: start worker processes 2025/04/16 14:28:10 [notice] 1#1: start worker process 30 2025/04/16 14:28:10 [notice] 1#1: start worker process 31 10.0.0.219 - - [16/Apr/2025:14:29:55 +0000] "GET / HTTP/1.1" 200 615 "-" "curl/8.5.0" "-" 10.0.0.219 - - [16/Apr/2025:14:35:05 +0000] "GET / HTTP/1.1" 200 615 "-" "curl/8.5.0" "-" 10.0.0.219 - - [16/Apr/2025:14:35:06 +0000] "GET / HTTP/1.1" 200 615 "-" "curl/8.5.0" "-" 10.0.0.219 - - [16/Apr/2025:14:35:06 +0000] "GET / HTTP/1.1" 200 615 "-" "curl/8.5.0" "-" 10.0.0.219 - - [16/Apr/2025:14:39:11 +0000] "GET / HTTP/1.1" 200 615 "-" "curl/8.5.0" "-" 10.0.0.219 - - [16/Apr/2025:14:39:11 +0000] "GET / HTTP/1.1" 200 615 "-" "curl/8.5.0" "-" 10.0.0.219 - - [16/Apr/2025:14:39:12 +0000] "GET / HTTP/1.1" 200 615 "-" "curl/8.5.0" "-"
0
Categories
- All Categories
- 242 LFX Mentorship
- 242 LFX Mentorship: Linux Kernel
- 815 Linux Foundation IT Professional Programs
- 366 Cloud Engineer IT Professional Program
- 165 Advanced Cloud Engineer IT Professional Program
- 83 DevOps Engineer IT Professional Program
- 131 Cloud Native Developer IT Professional Program
- 142 Express Training Courses & Microlearning
- 119 Express Courses - Discussion Forum
- Microlearning - Discussion Forum
- 6.6K Training Courses
- 40 LFC110 Class Forum - Discontinued
- 72 LFC131 Class Forum
- 49 LFD102 Class Forum
- 234 LFD103 Class Forum
- 16 LFD110 Class Forum
- 31 LFD121 Class Forum
- LFD123 Class Forum
- LFD125 Class Forum
- 16 LFD133 Class Forum
- 6 LFD134 Class Forum
- 17 LFD137 Class Forum
- 70 LFD201 Class Forum
- 3 LFD210 Class Forum
- 2 LFD210-CN Class Forum
- 2 LFD213 Class Forum - Discontinued
- 128 LFD232 Class Forum - Discontinued
- 2 LFD233 Class Forum
- 2 LFD237 Class Forum
- 24 LFD254 Class Forum
- 680 LFD259 Class Forum
- 109 LFD272 Class Forum
- 4 LFD272-JP クラス フォーラム
- 10 LFD273 Class Forum
- 233 LFS101 Class Forum
- 1 LFS111 Class Forum
- 2 LFS112 Class Forum
- 1 LFS116 Class Forum
- 3 LFS118 Class Forum
- LFS120 Class Forum
- 2 LFS142 Class Forum
- 2 LFS144 Class Forum
- 3 LFS145 Class Forum
- 1 LFS146 Class Forum
- 15 LFS148 Class Forum
- 8 LFS151 Class Forum
- 1 LFS157 Class Forum
- 63 LFS158 Class Forum
- LFS158-JP クラス フォーラム
- 4 LFS162 Class Forum
- 1 LFS166 Class Forum
- 3 LFS167 Class Forum
- 1 LFS170 Class Forum
- 2 LFS171 Class Forum
- 2 LFS178 Class Forum
- 2 LFS180 Class Forum
- 1 LFS182 Class Forum
- 5 LFS183 Class Forum
- 30 LFS200 Class Forum
- 737 LFS201 Class Forum - Discontinued
- 2 LFS201-JP クラス フォーラム
- 17 LFS203 Class Forum
- 111 LFS207 Class Forum
- 1 LFS207-DE-Klassenforum
- LFS207-JP クラス フォーラム
- 302 LFS211 Class Forum
- 55 LFS216 Class Forum
- 53 LFS241 Class Forum
- 50 LFS242 Class Forum
- 37 LFS243 Class Forum
- 13 LFS244 Class Forum
- 1 LFS245 Class Forum
- LFS246 Class Forum
- LFS248 Class Forum
- 79 LFS250 Class Forum
- 2 LFS250-JP クラス フォーラム
- LFS251 Class Forum
- 143 LFS253 Class Forum
- LFS254 Class Forum
- LFS255 Class Forum
- 6 LFS256 Class Forum
- LFS257 Class Forum
- 1.2K LFS258 Class Forum
- 9 LFS258-JP クラス フォーラム
- 135 LFS260 Class Forum
- 151 LFS261 Class Forum
- 41 LFS262 Class Forum
- 82 LFS263 Class Forum - Discontinued
- 15 LFS264 Class Forum - Discontinued
- 11 LFS266 Class Forum - Discontinued
- 22 LFS267 Class Forum
- 25 LFS268 Class Forum
- 29 LFS269 Class Forum
- 7 LFS270 Class Forum
- 199 LFS272 Class Forum
- 1 LFS272-JP クラス フォーラム
- 2 LFS147 Class Forum
- LFS274 Class Forum
- 3 LFS281 Class Forum
- 2 LFW111 Class Forum
- 257 LFW211 Class Forum
- 176 LFW212 Class Forum
- 12 SKF100 Class Forum
- SKF200 Class Forum
- 2 SKF201 Class Forum
- 789 Hardware
- 199 Drivers
- 68 I/O Devices
- 37 Monitors
- 98 Multimedia
- 174 Networking
- 91 Printers & Scanners
- 83 Storage
- 753 Linux Distributions
- 82 Debian
- 67 Fedora
- 17 Linux Mint
- 13 Mageia
- 23 openSUSE
- 147 Red Hat Enterprise
- 31 Slackware
- 13 SUSE Enterprise
- 350 Ubuntu
- 464 Linux System Administration
- 39 Cloud Computing
- 70 Command Line/Scripting
- Github systems admin projects
- 91 Linux Security
- 78 Network Management
- 101 System Management
- 47 Web Management
- 69 Mobile Computing
- 17 Android
- 28 Development
- 1.2K New to Linux
- 1K Getting Started with Linux
- 365 Off Topic
- 113 Introductions
- 176 Small Talk
- 26 Study Material
- 521 Programming and Development
- 291 Kernel Development
- 212 Software Development
- 1.1K Software
- 263 Applications
- 180 Command Line
- 3 Compiling/Installing
- 988 Games
- 311 Installation
- 79 All In Program
- 79 All In Forum
Upcoming Training
-
August 20, 2018
Kubernetes Administration (LFS458)
-
August 20, 2018
Linux System Administration (LFS301)
-
August 27, 2018
Open Source Virtualization (LFS462)
-
August 27, 2018
Linux Kernel Debugging and Security (LFD440)