If you want to test on Akamai staging network you normally lookup the IP address of the staging CNAME.
- your Akamai CNAME is mycompany.edgekey.net
- so you do something like this
>mycompany.edgekey.netcanonical name = e5663.dsce2.akamaiedge.net.
If you curl for this or spoof your hostfile you will see the staging header
But things are different if you use ChinaCDN. As Akamai has to decide on DNS level if a request is/is-not sent from China there is a DNS traffic manager added to the DNS resolving process, so the lookup will lokk like this
>mycompany.edgekey.net canonical name = mycompany.edgekey.net.globalredir.akadns.net.
lmycompany.edgekey.net.globalredir.akadns.net canonical name = e2929.g.akamaiedge.net.
The *.globalredir.akadns.net. will always guide you to the same IP, no matter if you add -staging or not.
The solution is to step behind the global redirector, using the numbered edgenode itself.
So, in our case, the requests resolves to
we would then lookup e2929.g.akamaiedge-staging.net
and get the IP
this can be used to spoof your hostfile.
In general, if you do not see the header
in your response you know you are not on the staging network.