Default connection time is 30 secs.
As you are facing a timout on your command, therefore you need to increase the timout of your sql command. You can specify it in your command like this.
// Setting command timeout to 2 minutes
cmd.CommandTimeout = 120