Brighthouse IPv6 - IPv4 Exhausted and Still Years Away?!?

Ok, rant time.

The final open IPv4 block of addresses was released from IANA which caused the final "triggered" release of the last 5 reserve IPv4 blocks. I think that most IT professionals new that this would happen, and most conservative estimates thought that it would occur in December of 2010. However, we wormed a few more months out of it and made it to February 2011.

Well, I have a static IP and run a business from it... So, I thought it was time to get my IPv6 address from Brighthouse / RoadRunner and start my transition. I called Brighthouse and asked for my shiny new 128-bit address.  The tier1 rep didn't know what an "IPv" was, but he recognized the word "business" so he passed me up the chain.

After advancing in queue to the next tier of support, I explained that IPv4 was nearly depleted and I wanted to remain in contact with potential customers, so I thought it was time that I get an IPv6 address.  The response I got was not that they were not prepared...it was that people are too dumb for such a long address and Brighthouse couldn't possibly support such a mass of stupid people.  He explained that since 128-bits is greater than 32-bits, that customers wouldn't be able to understand the address.  My experience here is that most non-IT persons do not understand IPv4 address space to begin with, so this argument is corporate fodder and ultimately makes no sense.

Well, anyway, I am not your average idiot [sic], so I pressed a bit further.

The rep further explained that "Brighthouse has plenty of IPv4 addresses remaining" and not to worry.  I'm not quite sure Brighthouse has done a proper job of educating their employees.  My concern is not that I will no longer be able to access Brighthouse services, but that as the rest of the world starts allocating IPv6 over the next few months, there will be no way for me to get to those networks and for those networks to get to me.  Again their argument is corporate fodder meant to assure the uneducated.

After explaining the whole "there are other networks in the world" argument to the Brighthouse rep, he said that he was not aware of any immediate plan for IPv6 and it would probably still be a couple of years out.  A couple of years?!?  Depletion of the remaining 5 subnet block will occur in less than 6 months!  This means IPv6 addresses will be allocated in their stead and that content will be inaccessible to IPv4 only users.  I will have to turn customers away because Brighthouse failed to meet a known address exhaustion deadline!

Comcast started Dual-Stack deployment at the end of January.  Don't get me wrong, I wouldn't touch Comcast with your router, but really, Comcast?  Brighthouse, TimeWarner, and RoadRunner, are you really going to let Comcast show you up?

Unallocated IPv4 Exhaustion: http://www.potaroo.net/tools/ipv4/

Test your IPv6 status: http://test-ipv6.com/


Asterisk - Defining the "sounds" directory.

I created a patch for Asterisk that allows for one to set the location of the "sounds" directory in /etc/asterisk/asterisk.conf just as one would set the location of the agi-bin (astagidir) directory or spool directory (astspooldir). The patch also checks for the existence of "/mnt/ramdisk/sounds" and uses that for the location if it does.

Just patch Asterisk and add "astsounddir => /path/to/sounds" to your asterisk.conf.

[Download Patch]
Author: Lott Caskey License: GPLv3 The patch adds the 'astsounddir' option to /etc/asterisk/asterisk.conf. This allows you to override Asterisk's sound directory without needing to make symlinks. If /mnt/ramdisk/sounds is present it will default the sounds location from /var/lib/asterisk/sounds to /mnt/ramdisk/sounds. diff -Naur asterisk- asterisk- --- asterisk- 2010-11-24 12:03:16.000000000 -0500 +++ asterisk- 2010-12-21 01:08:43.000000000 -0500 @@ -1456,7 +1456,7 @@ call is actually dialed */ /* make sure the priv-callerintros dir actually exists */ - snprintf(pa->privintro, sizeof(pa->privintro), "%s/sounds/priv-callerintros", ast_config_AST_DATA_DIR); + snprintf(pa->privintro, sizeof(pa->privintro), "%s/priv-callerintros", ast_config_AST_SOUND_DIR); if ((res = ast_mkdir(pa->privintro, 0755))) { ast_log(LOG_WARNING, "privacy: can't create directory priv-callerintros: %s\n", strerror(res)); return -1; diff -Naur asterisk- asterisk- --- asterisk- 2008-01-24 17:58:10.000000000 -0500 +++ asterisk- 2010-12-21 01:08:43.000000000 -0500 @@ -21,6 +21,7 @@ #define DEFAULT_DATA_DIR "${INSTALL_PATH}${ASTDATADIR}" #define DEFAULT_KEY_DIR "${INSTALL_PATH}${ASTDATADIR}/keys" +#define DEFAULT_SOUND_DIR "${INSTALL_PATH}${ASTDATADIR}/sounds" #define DEFAULT_SPOOL_DIR "${INSTALL_PATH}${ASTSPOOLDIR}" #define DEFAULT_TMP_DIR "${INSTALL_PATH}${ASTSPOOLDIR}/tmp" diff -Naur asterisk- asterisk- --- asterisk- 2007-12-20 04:55:05.000000000 -0500 +++ asterisk- 2010-12-21 01:08:43.000000000 -0500 @@ -35,5 +35,6 @@ extern const char *ast_config_AST_RUN_GROUP; extern const char *ast_config_AST_RUN_USER; extern const char *ast_config_AST_SYSTEM_NAME; +extern const char *ast_config_AST_SOUND_DIR; #endif /* _ASTERISK_PATHS_H */ diff -Naur asterisk- asterisk- --- asterisk- 2010-05-17 14:44:53.000000000 -0400 +++ asterisk- 2010-12-21 01:08:43.000000000 -0500 @@ -481,7 +481,7 @@ if (filename[0] == '/') { ast_copy_string(tmpf, filename, sizeof(tmpf)); } else { - snprintf(tmpf, sizeof(tmpf), "%s/%s/%s", ast_config_AST_DATA_DIR, "sounds", filename); + snprintf(tmpf, sizeof(tmpf), "%s/%s", ast_config_AST_SOUND_DIR, filename); } if ((fd = open(tmpf, O_RDONLY)) < 0) { ast_log(LOG_WARNING, "Unable to open file '%s': %s\n", tmpf, strerror(errno)); diff -Naur asterisk- asterisk- --- asterisk- 2010-11-29 02:27:09.000000000 -0500 +++ asterisk- 2010-12-21 02:41:41.000000000 -0500 @@ -233,6 +233,7 @@ char agi_dir[PATH_MAX]; char run_dir[PATH_MAX]; char key_dir[PATH_MAX]; + char sound_dir[PATH_MAX]; char config_file[PATH_MAX]; char db_path[PATH_MAX]; @@ -256,6 +257,7 @@ const char *ast_config_AST_AGI_DIR = cfg_paths.agi_dir; const char *ast_config_AST_KEY_DIR = cfg_paths.key_dir; const char *ast_config_AST_RUN_DIR = cfg_paths.run_dir; +const char *ast_config_AST_SOUND_DIR = cfg_paths.sound_dir; const char *ast_config_AST_DB = cfg_paths.db_path; const char *ast_config_AST_PID = cfg_paths.pid_path; @@ -485,7 +487,14 @@ ast_cli(a->fd, " Configuration directory: %s\n", ast_config_AST_CONFIG_DIR); ast_cli(a->fd, " Module directory: %s\n", ast_config_AST_MODULE_DIR); ast_cli(a->fd, " Spool directory: %s\n", ast_config_AST_SPOOL_DIR); + ast_cli(a->fd, " Var directory: %s\n", ast_config_AST_VAR_DIR); + ast_cli(a->fd, " Monitor directory: %s\n", ast_config_AST_MONITOR_DIR); + ast_cli(a->fd, " Data directory: %s\n", ast_config_AST_DATA_DIR); ast_cli(a->fd, " Log directory: %s\n", ast_config_AST_LOG_DIR); + ast_cli(a->fd, " AGI directory: %s\n", ast_config_AST_AGI_DIR); + ast_cli(a->fd, " Key directory: %s\n", ast_config_AST_KEY_DIR); + ast_cli(a->fd, " Run directory: %s\n", ast_config_AST_RUN_DIR); + ast_cli(a->fd, " Sounds directory: %s\n", ast_config_AST_SOUND_DIR); ast_cli(a->fd, "\n\n"); return CLI_SUCCESS; } @@ -2833,6 +2842,7 @@ struct ast_variable *v; char *config = DEFAULT_CONFIG_FILE; char hostname[MAXHOSTNAMELEN] = ""; + struct stat st; struct ast_flags config_flags = { 0 }; struct { unsigned int dbdir:1; @@ -2861,6 +2871,12 @@ ast_copy_string(cfg_paths.socket_path, DEFAULT_SOCKET, sizeof(cfg_paths.socket_path)); ast_copy_string(cfg_paths.run_dir, DEFAULT_RUN_DIR, sizeof(cfg_paths.run_dir)); + if (stat("/mnt/ramdisk/sounds", &st)==0) { + snprintf(cfg_paths.sound_dir, sizeof(cfg_paths.sound_dir), "/mnt/ramdisk/sounds"); + } else { + snprintf(cfg_paths.sound_dir, sizeof(cfg_paths.sound_dir), "%s", DEFAULT_SOUND_DIR); + } + ast_set_default_eid(&ast_eid_default); /* no asterisk.conf? no problem, use buildtime config! */ @@ -2909,6 +2925,8 @@ ast_copy_string(cfg_paths.run_dir, v->value, sizeof(cfg_paths.run_dir)); } else if (!strcasecmp(v->name, "astmoddir")) { ast_copy_string(cfg_paths.module_dir, v->value, sizeof(cfg_paths.module_dir)); + } else if (!strcasecmp(v->name, "astsounddir")) { + ast_copy_string(cfg_paths.sound_dir, v->value, sizeof(cfg_paths.sound_dir)); } } diff -Naur asterisk- asterisk- --- asterisk- 2010-10-06 09:48:27.000000000 -0400 +++ asterisk- 2010-12-21 01:08:43.000000000 -0500 @@ -245,7 +245,7 @@ /*! * \brief construct a filename. Absolute pathnames are preserved, - * relative names are prefixed by the sounds/ directory. + * relative names are prefixed by the ast_config_AST_SOUND_DIR directory. * The wav49 suffix is replaced by 'WAV'. * Returns a malloc'ed string to be freed by the caller. */ @@ -262,8 +262,8 @@ fn = NULL; } } else { - if (asprintf(&fn, "%s/sounds/%s.%s", - ast_config_AST_DATA_DIR, filename, ext) < 0) { + if (asprintf(&fn, "%s/%s.%s", + ast_config_AST_SOUND_DIR, filename, ext) < 0) { ast_log(LOG_WARNING, "asprintf() failed: %s\n", strerror(errno)); fn = NULL; }