X-Auth-Token changed itself
i wrote a script to write large number of files into my cluster system, and this morning i found in log that the auth-server came up to a problem, and the write operation cannot be executed. the log looks like this:
Nov 17 09:45:42 swift1 auth-server validate_
Nov 17 09:45:42 swift1 auth-server 127.0.0.1 - - [17/Nov/
it seems that the x-auth-token has failed to be validated. so i check the file which had saved the x-auth-token before.
root@swift1:~# cat token
AUTH_tkeea74a86
the token saved in the file was used in my request(write operation) to the cluster. so the one in log is the same as that in the file.
it seems the x-auth-token is not valid, so i fetched the x-auth-token again like below.
root@swift1:~# ./swift_
swift_create_token is a script like this:
#!/bin/bash
if [ $# -ne 4 ]
then
echo "Usage:"
echo " swift_create_token <account> <user> <password> <auth-server-
exit 1
fi
curl -k -v -H "X-Storage-User: $1:$2" -H "X-Storage-Pass: $3" "https:/
grep X-Auth-Token token_tmp | awk -F ": " '{print $2}' > token
grep X-Storage-Url token_tmp | awk -F ": " '{print $2}' > url
amazingly, i found that the x-auth-token has changed to something below!
root@swift1:~# cat token
AUTH_tk48ae64f7
I used the new x-auth token above in my request and the write operation was OK eventually.
I wonder how can the x-auth-token had been changed?
Question information
- Language:
- English Edit question
- Status:
- Solved
- Assignee:
- No assignee Edit question
- Solved by:
- gholt
- Solved:
- Last query:
- Last reply: