Feb 192016
 

I was receiving this error when trying to build an RPM containing a very large number of files. The files contained USPS zip code data for the entire United States. When building the RPM, I would receive the following error:

error: Unable to create immutable header region

I tried searching for a solution and came across this bug: http://rpm.org/ticket/862. So, basically, this is an arbitrary limit imposed by RPM which doesn’t appear to have a clean workaround.

My method for bypassing the limit was to use the suggestion at https://bugzilla.redhat.com/show_bug.cgi?id=913099#c8. I built an RPM which split the zip code data by the first digit. The resulting spec file looks something like this.

Name:           usps-zipdata
Version:        0.1
Release:        1%{?dist}
Summary:        USPS zip code data

License:        custom license
URL:            https://example.com/uspsdata
Source0:        %{name}-%{version}.tar.bz2

BuildArch:      noarch
BuildRequires:  coreutils, bzip2
Requires:       usps-zipdata-0 = %{version}-%{release}
Requires:       usps-zipdata-1 = %{version}-%{release}
Requires:       usps-zipdata-2 = %{version}-%{release}
Requires:       usps-zipdata-3 = %{version}-%{release}
Requires:       usps-zipdata-4 = %{version}-%{release}
Requires:       usps-zipdata-5 = %{version}-%{release}
Requires:       usps-zipdata-6 = %{version}-%{release}
Requires:       usps-zipdata-7 = %{version}-%{release}
Requires:       usps-zipdata-8 = %{version}-%{release}
Requires:       usps-zipdata-9 = %{version}-%{release}

%description
Static USPS zip code data.

%package 0
Summary:        USPS zip code data 0*

%description 0
Static USPS zip code data for zip codes starting with the number zero.

%package 1
Summary:        USPS zip code data 1*

%description 1
Static USPS zip code data for zip codes starting with the number one.

%package 2
Summary:        USPS zip code data 2*

%description 2
Static USPS zip code data for zip codes starting with the number two.

%package 3
Summary:        USPS zip code data 3*

%description 3
Static USPS zip code data for zip codes starting with the number three.

%package 4
Summary:        USPS zip code data 4*

%description 4
Static USPS zip code data for zip codes starting with the number four.

%package 5
Summary:        USPS zip code data 5*

%description 5
Static USPS zip code data for zip codes starting with the number five.

%package 6
Summary:        USPS zip code data 6*

%description 6
Static USPS zip code data for zip codes starting with the number six.

%package 7
Summary:        USPS zip code data 7*

%description 7
Static USPS zip code data for zip codes starting with the number seven.

%package 8
Summary:        USPS zip code data 8*

%description 8
Static USPS zip code data for zip codes starting with the number eight.

%package 9
Summary:        USPS zip code data 9*

%description 9
Static USPS zip code data for zip codes starting with the number nine.

%prep
%setup -q

%build

%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT/var/usps
tar xvf zip.tar.bz2
mv zip $RPM_BUILD_ROOT/var/usps/

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%dir /var/usps/zip
%dir /var/usps/zip/MSS
/var/usps/zip/MSS/[a-z]*

%files 0
/var/usps/zip/MSS/0*

%files 1
/var/usps/zip/MSS/1*

%files 2
/var/usps/zip/MSS/2*

%files 3
/var/usps/zip/MSS/3*

%files 4
/var/usps/zip/MSS/4*

%files 5
/var/usps/zip/MSS/5*

%files 6
/var/usps/zip/MSS/6*

%files 7
/var/usps/zip/MSS/7*

%files 8
/var/usps/zip/MSS/8*

%files 9
/var/usps/zip/MSS/9*

%changelog
* Thu Feb 18 2016 Sol Jerome  - 0.1-1
- create new RPM for USPS zip code data
 Posted by at 11:10
Aug 192010
 

I recently switched to Comcast for my Internet Service Provider. The transition hasn’t been pleasant. I have had a number of issues with them. However, by far the most annoying issue is with their “domain helper service“. This post should help any others who fall victim to this unexpected behavior.

Basically, what they do is assign you one of their special DNS servers from http://dns.comcast.net/dns-ip-addresses.php which return incorrect results:

$ nslookup thisdomaindoesnotexist 68.87.72.134
Server:         68.87.72.134
Address:        68.87.72.134#53

Non-authoritative answer:
Name:   thisdomaindoesnotexist
Address: 208.68.139.38

when the real response should be:

$ nslookup thisdomaindoesnotexist 68.87.85.98
Server:         68.87.85.98
Address:        68.87.85.98#53

** server can't find thisdomaindoesnotexist: NXDOMAIN

In my mind, this amounts to hijacking my NXDOMAIN responses which violates RFC2308 and is even outlawed in the UK! I could have fixed this easily by modifying the nameservers listed in /etc/resolv.conf. The problem with this is that I would have to do it for all of my machines. Another solution is to set the DNS servers in my router’s configuration (since it provides them during DHCP). The problem with this is that I again end up doing some manual configuration on my end for a problem which Comcast caused.

Of course this leads to all sorts of nastiness. I first noticed this nonsense while clicking on a link for a site that used to exist. This lead me to their hideously ugly (and amazingly useless) search page. After looking around, I realized other people had similar feelings. Just look at the blog post linked to previously. Not one enthusiastic comment about how useful this is.

So, I decided to try and disable this thing on my own. After all, they are nice enough to provide you instructions on how to do it yourself. The only problem with that is the necessary options don’t even show up on my account!

The next step was to initiate a chat with their technical support to get them to update the account settings for me. Unfortunately, this did more harm than good. They tried to reset my router remotely (which obviously kicked me out of the chat session). Not only that, but the router reset never completed properly.

Okay, so next step was to call (I no longer had internet access after all). The first person I talked to wasn’t even able to reset my router again! They were convinced that this was a problem that needed to be solved by having a technician come out. I was not able to convince her otherwise. So, I scheduled the technician.

I then called back immediately. I did not mention the mistake made by the previous person in chat. I simply requested that they activate my service (as I needed done when I first got service). This time, the person on the line was able to activate my service. I figured since they were able to do that, maybe they would be able to help me with my problem. So, I tried explaining it and was transferred to someone in their “technical support” department. This person at least listened to what I was saying and looked at the links with the instructions I was trying to follow. She even logged into my account and was able to see that the options were not showing up. However, she was also unable to help and speculated that the technician might know something else (not likely since they’re usually just contractors).

My last resort was emailing Comcast support and explaining all of this in my email. A few days later, I received an email confirming that this had been done. Sure enough, I checked the nameservers listed on my router and they were using the opt out servers listed at http://dns.comcast.net/dns-ip-addresses2.php. Finally, they fixed my problem and all it took was a simple email.