This is the solution video for the core DNS lab.
So for the first question, identified a solution implemented in the cluster.
So let's go to the Domhnall and I still get.
Deployment in the tube system namespace.
And here we have a department called DNS, but two parts.
So select gaudiness as the answer.
How many parts of the DNA server are deployed?
So we already saw that it's two out of two ports which are ready.
So the answer is to.
What is the name of this service created for accessing Codina?
So let's go back to the DOMHNALL and check the service to the same thing as before, but we'll just
look up service and hear the name is Kube Dash DNS.
What is the type of decoding and server that should be configured on postal services so we can just
look up at the IP address of the code in service?
So let's go back and see the same command and the cluster IP here is 10 or 96 dot zero 10.
There is the configuration file located for configuring decoding a service.
So let's inspect the accordionists deployment.
So in this case, I'm going to run cutesie to describe deployment's go DNS.
The system namespace.
And look, let's look up at the comments and arguments for this deployment, for the continued running
on this deployment, and here we can see that the configuration file uses Itzik or DNS or file.
How is the court file past and to the court in a sport, again, we can look up at the configuration
for the deployment and here if you see the configuration file is located at ETEK DNS.
And if you observe underneath, we have a mode called ATC Code DNS, which is from a config volume,
which is of type config map.
So it's basically mounting a conflict map on that part cadenas, and that's the way it is loading this
file when the pod starts up.
So the answer is configured as a conflict map object.
What is the name of the conflict map object created for the CORFO that is called DNS?
What is the root domain zone configured for this group when it is cluster to identify those people,
explore the code in this?
Conflict map.
So let's run cutesie to describe s.m, which is short for conflict map and accordionists conflict,
Mabern here under this file, the core file, we can see that the cluster domain uses cluster or local.
So that's here.
So the answer should be clustered local.
We have deployed a set of pods and services and the default and petroleum species inspect them and go
to the next question.
So first, let's inspect the ports and deployments on all the spaces, specifically default and payroll.
So let's try to get ports.
So that's on the default namespace.
And we can see that we have a few ports by the name of H.R. Test.
Simple.
We have one simple one.
Now let's do the same.
But in the.
Payroll namespace, and here we have.
Port called VEB.
Let's move on to the next question.
What name can be used to access the HRR Web server from the test application, you can execute a command
on the test for the test or we can make use of the application UI, which is located on top of it.
So we know from the previous command that both H.R. and Test are in the same namespace, which is the
default namespace.
So for them to reach each other or using a service name, they do not have to specify the fully qualified
domain name or the name of the namespace.
So we see that there is a service by the name of Web service and the default namespace.
So let's first establish the fact that the Web service does belong to the port called H.R..
To do that, we will inspect the labels and selectors on the service.
First, let's try still describe as we see the observers and here we can see that the selectors name
is equal to HRR.
Next, let's validate that the same label is used by the port.
So, Ron, you get part.
H.R. Anshul labels.
And here we can see that it matches the Selecter used for the Web service.
So to access this application, we can try to access Web service from the test application, so let's
do that now.
So let's copy paste the name of the service, which is Web service.
And here we can see that the port uses 80, so let's try to resolve it and see if the connectivity from
the test application works.
So the whole thing should be Web service.
And they put it in here, we get the result, saying that this is the server, so it's working well
so we can use Web service as the name to resolve which of these names cannot be used to access the service
from the test port.
So all of these options are correct.
We can use Web service.
DOT default, which will default, is the namespace.
We can also use Web service, dot default, dot, SBC, because it's a service.
The only name we cannot use is web service.
Dot default dot part.
Which of the balloon name can be used to access the payroll service from the test application so we
know that the payroll service is not in default namespace and the test application is so to access the
Web service on payroll application will have to up in the name of the namespace.
But let's test that.
So let's add that payroll.
And see the result.
So this does show you that it is able to connect to the payroll server, so the answer is Web service,
DOT payroll.
Which of the blue name cannot be used to access the payroll service from the test application?
So here we can use all of the names to access the service in the payroll namespace, but will notice
that one of them.
Has the value of Web service, payroll, NVC dot cluster, which is not the complete fully qualified
domain name the domain as cluster dot local.
So we cannot connect to it just as we see dot cluster.
So let's test that now.
And you see that it fails.
But if we append cluster dot local.
Which includes the full domain, it would work, but we can also use other options, such as payroll
or SBC or just payroll.
So the incorrect option here is as we see the cluster, we just deployed a Web server called Webapp
that accesses a database called MySQL.
However, the Web server is failing to connect to the database server, troubleshoot and fix the issue.
They could be in different names.
So, yeah, let's first try to find out the names faces that these pods and deployments are on.
So let's go to the Domhnall.
And first, let's run, you get parts, all news pieces, so this will show up any new polls that have
been created and different namespace.
So we see that there is a port by the name of my sequel's, which is now in the payroll part, the payroll
namespace.
And there is a new port.
And the default names is what it looks like.
It's a deployment just by looking at the name so that as of a deployment.
So let's run Cuba.
You get deployment's.
And the only space and here we have a webapp deployment which was created a few moments ago.
And in the payroll namespace, that the MySQL part, which the webapp deployment is trying to connect
to.
So let's open the Web server and we see that the Web page shows a failed result and here we have environment
variables.
DB holes is equal to my school, so it is not trying to connect to the payroll namespace in this case.
It's trying to look for MySQL and the default space.
And because it does not exist, it feels.
So let's edit our deployment, and for that, we will face the definition file for the webapp deployment
using Kubek to get deployments.
Web app Dash Oyamel.
And will be redirected to.
Once that is done, let's open it up using the editor and navigate to the environment section.
And on the environment, we will change the value for DBI underscore host to Michael Dot payroll because
this service resides on the payroll namespace.
Once this is done, we can save and exit this file and we can still apply to update the pod on this
deployment.
But just to validate, we see that the service called my school is in payroll namespace and now we can
create.
New deployment.
So let's try and apply the EFF Web app demo so they should recreate the pod.
Don't need the old pod and create a new one and it's please.
With the updated environment variable.
So now to validate because the partisan is running said, let us check the Web application.
Let's refresh it and now you see that it's working as expected.
For the last question from the airport, and that's been my Secret Service and they the output to a
fire, so we know that they are partners in the defining space.
So we'll use cubicle exec command and.
This case will use Dash, Dash and let's look up and let's test if.
We can run and look up with just the name Michael.
Which should fail because there is no service by that name in the default namespace, but let's try
that anyway.
As you can see, it's failing, but let's add my school payroll and it should resolve the IP address
of the service.
So now let's redirect this to the file, which is Slashdot.
And it's like a..
Look up.
Dot out.
And that should be it, let's validate.
So the fire looks correct.
And our answer is correct as well.
So that was the last question.
Thank you for joining me in this solution.
We do.
I'll see you in the next one.