I'd like to set my aws cli to use a new AWS account on my machine. 

So I backed up and deleted `~/.aws/config` and `~/.aws/credentials` files.

After the deletion, I typed `aws configure` to set the *Access Key ID* and *Secret Access Key* of the new AWS account.

But then I got an error saying 

> 
> botocore.exceptions.ProfileNotFound: The config profile
>  (my\_profile\_name) could not be found
> 
> 
> 

`my_profile_name` is the profile name of my old AWS account.

How does aws cli remember my old profile name? 

How can I reset it so that I can use new *Access Key ID* and *Secret Access Key*?

I also find that typing `sudo aws configure` is able generate new `~/.aws/config` and `~/.aws/credentials` files. 

But the [getting started tutorial](http://docs.aws.amazon.com/cli/latest/userguide/cli-chap-getting-started.html) doesn't say that you need add `sudo` before `aws` command. So I don't think this is a good solution for my case.

The *profile* I mentioned in this post refers to a setting in `~/.aws/config`:

```
[profile my_profile_name]
region = ap-northeast-1
output = json

```