Like many people, I have several SVN repositories that contains several projects. I've decided to convert one of these repositories to Mercurial for several reasons.
I've successfully converted the repository using instructions located here. The new hg repo includes everything; all history and the correct tags. The conversion worked great.
Now, I need to "diverge" the two projects but I want to maintain the history on both sides. I'm wondering if there is a way to do this appropriately to prevent things like accidentally importing the changesets in to the others repository down the road.
To be clear, I don't care that each repository will have the same history for the current change set back (in fact, I want this). I just want to somehow indicate that they are "different" repositories from now on...
Update: Can someone elaborate on the --force? At what point will that flag be necessary. At http://www.selenic.com/mercurial/hg.1.html, under "pull", I see that the -f, --force options are to "run even when remote repository is unrelated" but what makes a repository unrelated? To me, since I cloned from the original repository they are (or could be) related....
Update: What I'm trying to prevent is allowing one repo to be pulled in to the other repo after some time has passed. (Which is now the case.) I wrote a script that produce the problem. And accomplishes exactly what I don't want to happen (It's a windows batch file):
#echo off
REM - First, create two distinct repos.
REM - Add some files to each.
MD test1
MD test2
cd test1
hg init
REM - Do several writes and commits to give content to the repo.
echo This is some text for test1 > test1.txt
echo This iss some more text; blah blah; >> test1.txt
echo Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer sapien velit, hendrerit sit amet ultrices nec, malesuada a mauris. Mauris eget nisi sit amet diam sodales tristique nec at turpis. Nam viverra pulvinar est, quis accumsan nunc fringilla ut. Nullam eu massa sapien, ac molestie magna. Curabitur nec pharetra nibh. Pellentesque velit dui, placerat vel porta eget, malesuada vitae dolor. In a lectus vel sapien imperdiet fringilla quis eu odio. Donec pellentesque ante nec est iaculis a aliquam nibh varius. Vivamus sit amet dolor non lorem ullamcorper ultricies quis in risus. Mauris eget orci leo. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Mauris ut lorem lacus. In hac habitasse platea dictumst. Mauris pellentesque purus non elit molestie vehicula. >> test1.txt
echo This is another text file for test1 > test2.txt
hg addremove
hg commit -m"First commit on test1"
echo Nunc mollis, neque vel tempus iaculis, eros erat egestas metus, vitae condimentum tortor tortor id sem. Integer ac ante quis nisl condimentum iaculis. Vestibulum et quam vel lectus porta ultricies. Donec ultricies dignissim sollicitudin. Morbi sit amet est urna, a bibendum felis. In aliquet, tortor nec consequat ultricies, sapien diam eleifend nulla, in ullamcorper eros sapien ac magna. Phasellus sit amet congue quam. Nulla gravida justo aliquam libero tristique non tempor nunc mollis. Suspendisse venenatis tincidunt massa, a tempus odio blandit non. Suspendisse egestas orci lorem. Curabitur bibendum nibh quis elit tempus id suscipit nisl viverra. Pellentesque placerat nisl at felis porta laoreet. >> test1.txt
hg commit -m"second commit on test1"
echo Nunc placerat cursus scelerisque. Sed ac magna lacus, quis facilisis elit. Praesent mattis purus in urna congue auctor. Fusce pellentesque scelerisque dictum. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Vivamus vulputate nunc quis ante laoreet posuere. Curabitur ante turpis, blandit vitae dapibus vitae, convallis at tortor. Sed augue leo, fermentum id consequat et, accumsan in neque. In pellentesque luctus nisi, ac sagittis nisl condimentum tincidunt. Cras nec dui vitae purus adipiscing consectetur id at mi. Vestibulum quis est vitae purus dictum mollis. Phasellus ultrices rhoncus eleifend. Sed sit amet euismod orci. Curabitur id turpis tortor, nec mollis neque. Praesent egestas augue vitae sem fringilla at molestie lacus venenatis. >> test1.txt
hg commit -m"thrid commit on test1"
echo Suspendisse nec porta velit. Donec aliquet mi vel felis tempor vehicula vitae interdum quam. Phasellus tempor orci at ligula adipiscing sagittis. Quisque faucibus accumsan dui vel facilisis. Pellentesque laoreet quam vel nisl mattis ac venenatis sapien suscipit. Nam eget dictum risus. Proin quam magna, volutpat quis congue vitae, dapibus et mi. Etiam tempus purus ut massa sodales sed cursus odio ultrices. Ut vel dictum urna. Fusce blandit dignissim nibh a tempus. Nullam libero arcu, feugiat vel sollicitudin vitae, lacinia pulvinar enim. Nulla hendrerit faucibus tortor, sit amet convallis velit vehicula ut. Cras leo sem, fermentum eu adipiscing non, bibendum et lacus. Nulla volutpat tortor non libero feugiat fermentum id quis sem. Vivamus lobortis nibh quis diam semper feugiat. Phasellus ac lobortis purus. Vivamus at mi sem. Quisque accumsan consequat placerat. >> test1.txt
hg commit -m"fourth commit on test1"
cd ..
cd test2
hg init
echo Nala is a cat >> myCats.txt
hg addremove
hg commit -m"first commit on test2"
echo Simba is a cat >> myCats.txt
hg commit -m"2nd commit on test2"
echo Nanoon is a cat >> myCats.txt
hg commit -m"3rd commit on test2"
cd ..
REM ------------------------------------------------------------------------------------------------------------------------------------------------------
hg clone --pull test1 test-combined
cd test-combined
hg pull ../test2
echo -
echo You should have gotten a "abort: repository is unrelated" error.
echo this is from attempting to pull test2 in to the test-combined. Can't without --force flag.
echo This is another file for combined repo > combinedRepo.txt
echo This should be unique to test-combined >> combinedRepo.txt
hg addremove
hg commit -m"1st Change to combined repo"
echo Fusce lectus arcu, cursus et dictum et, ultrices ut magna. Cras ultrices leo ac arcu commodo auctor. Pellentesque commodo sem et elit euismod posuere. Nam cursus, nisl ut placerat tincidunt, diam ante congue felis, id facilisis sem eros nec augue. Phasellus vel interdum est. Nunc at tellus non dui aliquam placerat nec placerat augue. Vestibulum justo sem, laoreet et blandit eu, mollis a nibh. Cras convallis, turpis quis vulputate euismod, risus neque convallis dui, posuere eleifend dolor quam ut dui. Integer pharetra porttitor lorem, vitae commodo mi semper non. Duis ipsum nisi, vulputate vel cursus ut, consectetur eu tellus. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Fusce lobortis quam molestie leo scelerisque blandit. Ut massa neque, dapibus rutrum porta et, molestie vitae augue. Mauris eu erat a turpis suscipit viverra. Praesent vitae ante non dui volutpat ullamcorper eu in nisl. >> combinedRepo.txt
hg commit -m"2nd Change to combined repo"
cd .hg
rem - Replace the hgrc file where we blank out the default file.
echo [paths] > hgrc
echo default = >> hgrc
cd ..
cd ..
REM - We are not back in the starting folder...
REM ------------------------------------------------------------------------------------------------------------------------------------------------------
cd test1
echo A third file to make yet another commit in the repo. > myThirdFile.txt
hg addremove
hg commit -m"a third file to make this (test1) different than test-combined"
cd ..
REM - Retry the pull - Same source but diverged repos.
cd test-combined
hg pull ../test1
ECHO -
ECHO The pull just executed (in test-combined) succeeded but we want to prevent this.
ECHO Here is the log for test-combined
hg log
cd ..
#echo on
To run this, create an empty directory and save the text in the code block in to a .cmd file. Open a command window and navigate to the file and execute the .cmd.
You'll see the following above the log text:
added 1 changesets with 1 changes to 1
files (+1 heads) (run 'hg heads' to
see heads, 'hg merge' to merge)
The log text shows that the two repos were, indeed, combined. In my ideal solution, this would have resulted in an error or a request for the --force flag.
Update (9/10/2009): The hg convert didn't work for what I needed.
Use hg convert again with its filemap option to filter your files.
diverge>hg init repo
diverge>cd repo
diverge\repo>echo some text > file1.txt
diverge\repo>hg ci -A -m "added first file"
adding file1.txt
diverge\repo>echo more text > file2.txt
diverge\repo>echo 123 >> file1.txt
diverge\repo>hg ci -A -m "some changes and new file"
adding file2.txt
diverge\repo>hg log
1[tip] 0f37e61d075b 2009-09-11 10:35 +0200 wierob83
some changes and new file
0 b04d9d12fb1d 2009-09-11 10:34 +0200 wierob83
added first file
diverge\repo>cd ..
diverge>echo include file1.txt > files-in-repo-one.txt
diverge>echo exclude file1.txt > files-in-repo-two.txt
diverge>hg convert --filemap files-in-repo-one.txt repo new-repo-one
initializing destination new-repo-one repository
scanning source...
sorting...
converting...
1 added first file
0 some changes and new file
diverge>hg convert --filemap files-in-repo-two.txt repo new-repo-two
initializing destination new-repo-two repository
scanning source...
sorting...
converting...
1 added first file
0 some changes and new file
diverge>cd new-repo-two
diverge\new-repo-two>hg out ..\repo
comparing with ..\repo
searching for changes
abort: repository is unrelated
diverge\new-repo-two>hg push ..\repo
pushing to ..\repo
searching for changes
abort: repository is unrelated <-- can't push because its an independent repo
So it should have worked, but:
diverge\new-repo-two>cd ..\new-repo-one
diverge\new-repo-one>hg out ..\repo
comparing with ..\repo
searching for changes
1[tip] 62119640bde6 2009-09-11 10:35 +0200 wierob83
some changes and new file
the second repo seems to be still related (which I didn't know before ;).
I'm not sure if this is the intended behavior or a bug.
Update:
You can pull from the original repository if one of the created sup-repositories is still related. This happens when the splitting process does not split changsets at the beginning of the branch because these changsets do not contain files that should end in different subrepos. Hence, there is no need to create a new changset.
Clone the repository, then simply remove the original remote repo path from the new clone (so that it's impossible to push changes back to the old repo) and you should have a new completely independent repository.
To answer the part of your question concerning related repositories: two Mercurial repositories are related if they share a common root.
More precisely, two repositories A and B are related if they share one or more changesets. Let's say A and B share a changeset X. By "changeset X" I mean a changeset with hash X -- the hash value is the identity of a changeset. The hash value is computed recursively from the hash values of the parent changesets, the date, the committer, and the change itself. This implies that both A and B must share the parent changeset of X. Continuing like this, we see that A and B must share a common root changeset, which is an ancestor of changeset X.
This gives us the common definition of being related: they must share a common root. You will normally only have one root changeset and you can look at it like this:
hg log --rev 0
For your case, my guess is that convert has created the same root changeset in both conversions. You should check with hg log in both clones to verify that they indeed are related. That should also tell you something about why they are related.
If your filemaps really do include different subtrees in the two conversions, then I cannot see how the repositories can be related. So perhaps you have an overlap in your include/exclude rules so that the first changeset is equal in both conversions?
Diverging a repository is easy enough; just clone/push/pull as you see fit. Mercurial will regard the diverged repositories as related. There's no way in standard mercurial to stop a pull from a related repository from succeeding; "hg pull" assumes you know what you're doing.
If a whole bunch of unwanted changesets from diverged repositories do get pulled, you can clear out the changesets you don't want by:
Rename the repository
Clone the renamed repository back to the original name, using -r to
select the head you do want.
(Optional) push the heads you've got in the confused repository to
the diverged repositories as appropriate so you don't lose
anything.
Delete the renamed repository.
Depending on your environment you may be able to setup something with people, file permissions and/or web services to guarantee what you want.
While there might be a different solution to my given problem, I ended up writing a script that created a fresh repo and brought things in to it.
Since the script was external to Mercurial, Mercurial assigned new changesets ID (which ultimately gave me a new root) and essentially diverged the repo. My script did what (I suppose) hg convert does but it did it in such a way that the resulting repositories were considered different. If I had re-merged them (for the sake of argument) they would have not represented their source. Each changeset would have ran parallel up until I executed the merge command on this hypothetical re-merging.
If you really want to prevent people from combining the repos, relying on hg push rejecting unmerged heads is not very reliable; a simple cd one && hg fetch two && hg push would quietly merge them and combine the repos. If you really want to prevent this, it is possible to write a pretxncommit hook on the server which (for each of the two repos) rejects any attempt to push a particular changeset known to be only in the other one.
Related
I am using sed in package.json file to substitute the text.
But it does not replace the content.
Please help me solve this issue. I am using windows 10 and already installed sed (GNU sed version 4.2.1)
"replace": "sed -i \"s/<style type=\"text\\/css\">/<style type=\"text\\/css\" data-premailer=\"ignore\">/g\" ./dist/news.html"
Suggesting to try awk gsub() function instead of sed. awk use single quote.
I hope ' will prevent expansion of all " in gsub() function.
"replace": "awk '{gsub("<style type=\"text\\/css\">","<style type=\"text\\/css\" data-premailer=\"ignore\">");print}' ./dist/news.html"
Note that:
\\ is treated differently in awk. You might need \\\\
The output/result is not in the same file (sed -i not possible) but sent to stdout. You might want to do file redirection with > .
"replace": "awk '{gsub("<style type=\"text\\/css\">","<style type=\"text\\/css\" data-premailer=\"ignore\">");print}' ./dist/news.html > ./dist/news.1.html"
Worst case:
You can always create a batch script replace.bat to pack your scripts:
replace.bat
sed -i "s/<style type=\"text\\/css\">/<style type=\"text\\/css\" data-premailer=\"ignore\">/g\" %1
package.json
...
"replace": "cmd.exe -c 'replace.sh ./dist/news.html' "
...
Windows note:
In windows you can use powershell replace cmdlets instead of sed.
Also if you are comfortable with Linux, install windows wsl subsystem and work in Linux environment.
I'm working on a VHDL project in Microsemi Libero.
When I click "Simulate" in the Libero GUI, modelSim starts up and I get to see the results of my simulation.
I'd like to get the same response from a TCL command.
I can do "Execute Script...", and point Libero at a .TCL file containing the single line
run_tool -name {SIM_PRESYNTH}
...and this appears to work just fine (I get messages like "Starting Simulation...Simulation completed...The Execute Script succeeded")... except I don't get a modelSim window opening up to show me my simulation results.
How do I get modelSim to open at the end of a simulation using a TCL command?
many thanks
Just a guess, 7 months late.
In Libero ISE if I want Synplify to popup, in the IDE, I click "Project", then "Profiles" and I set the synthesis tool not to run in batch mode.
Perhaps you can do the same for the simulator, or add a profile, which in tcl would look like this:
add_profile \
-name {Synplify_b} \
-type {synthesis} \
-tool {Synplify} \
-location {somewhere} \
-args {-batch} \
-batch 1
select_profile -name {Synplify_b}
I have just installed Mura CMS.
I have Lucee installed and setup. However, it seems I am not completely "there" yet.
I can get to the Mura Page, but something seems missing:
When I go to: http://localhost:8888/cms I get a: 404 requested page could not be found and then right below this, we see:
Sample Modal Window This is just a sampleā¦
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent
suscipit iaculis libero sed tristique. Quisque mollis dolor non tellus
placerat vitae sodales lectus porta. Curabitur ut suscipit tellus.
Maecenas rhoncus, ante etc.
Environment is:
LINUX Mint (Rebecca 17.1) - It is my personal laptop
MySQL 5.5 (from Software Manager)
MySQL WorkBench (Created Mura DB and User)
Lucee Express 4.5.1.000 (and also includes Tomcat 8) - Created the DSN in server
I am wanting to work with Mura as I am on a migration project to Mura from another CMS.
I did follow the information it seems to be the most relevant to start with Lucee: Installing Tomcat and Lucee on OS X using the lucee.war file
It seems I am missing something pretty simple at this point as is shown by this screen cap.
It does not look anything like the admin panel from their site:
I wound up getting some additional help. These steps were what was used under Linux Mint.
Setup MySQL and MySQL Workbench or phpMyAdmin would work as well
Created a new database and database user as directed in the Installation.txt from Mura
Insure that you have Lucee configured (creating the DSN) and that you are able to login
Moved Lucee Express to /home/your_home/lucee and made sure that Lucee works
Deleted all of the content from /home/your_home/lucee/webapps/ROOT
Extracted out the contents of the Mura.zip into /home/your_home/lucee/webapps/ROOT
Changed /home/your_home/lucee/webapps/ROOT/config/settings.ini.cfm at line 27 to be context= (blank)
Ran startup.sh at /home/your_home/lucee/bin
Navigated to http://localhost:8888 and the site comes up fine and was able to login.
Thanks!
Addressing the CSS issue
When a non standard ports, the base tag needs to be set
<base href="http://localhost:8888/mura-6.2.6271/">
OR perhaps
<base href="http://localhost:8888/mura-6.2.6271/admin">
This is set in a layouts file
Try editing your /config/settings.ini.cfm file by setting the context attribute to the value or the nested path to the Mura root. So if the Mura is access via /cms/admin the context value would be /cms
context=/cms
The reload the application by putting ?appreload in at request to the Mura root. The appreloadkey is also configurable in the settings.ini.cfm.
Im trying to find and replace all "^A" characters with a "\t" so that I can import the data into a mysql database. The command Im using on OSX is:
sed -i '' 's/^A/\t/' item_info_20130203 > item_info_20130203_tab
This just deletes all the contents in the file. Where am I going wrong?
The command should actually be something like this:
sed 's/'`echo "\001"`'/\t/g' item_info_20130203 > item_info_20130203_tab
or the more modern way
sed 's/'$(echo "\001")'/\t/g' item_info_20130203 > item_info_20130203_tab
or to affect the original file:
sed -i 's/'`echo "\001"`'/\t/g' item_info_20130203
If you are using GNU sed, you can use this:
sed -i 's/\x01/\t/g' item_info_20130203
According to this post, sed's -i option finds/replaces text in the original file, so the syntax > item_info_20120203_tab at the end of your command is a NOP and hence the output file is empty.
There must be something really obvious I am missing, but here goes:
Most of the content of our web pages is generated either by server side includes or post page load AJAX calls, so the size of the HTML files is generally fairly small. However, when creating a test page, without anything complicated in it whatsoever I found that if the page size went over 8000 characters the server does not transfer the page.
This is an example file:
<!DOCTYPE html>
<html>
<head>
<title>Rubbish</title>
</head>
<body>
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.<br />
Repeat last line 16 times to give 17 complete lines in total. Then add this part of a line:
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliq.<br />
</body>
</html>
The above is a total of 8001 characters which does not load with the message 'Safari cannot load the page because the server unexpectedly closed the connection' and variations on that with Firefox and Chrome. Removing the final full stop, or any other character takes the character count down and so the page loads as expected.
Could anyone give me a clue about what I am missing in not being able to load such a straightforward file?
AN ANSWER (sort of):It was apparent that it was mod_deflate causing the issue so after some googling I asked on serverfault if anyone knew how to change the maximum size. There were no responses so I created a shell file and included the original 8000 character file as a server side include (SSI) and it now works as expected. Still no idea why there is a limit on plain HTML but none on SSIs, but I don't have time to worry about it any longer.
EDIT: Removed the 'SetOutputFilter DEFLATE' directive and the page now loads, which suggests that it is indeed th deflate module that is causing the problem. Adding 'DeflateBufferSize 10000' (or indeed 'DeflateBufferSize 2048') does not make any difference to the size supported so I'll close this question and ask about module deflate on server fault.
EDIT: Sorry, should have mentioned that we are using Apache 2.2.17 on Fedora 14. This is on a virtual machine on my laptop so no external factors are involved.
EDIT: Another thing I should have added is that there is nothing in the Apache error log even with loglevel set to debug. The access log gives a '200' message but with the number of characters sent set as '-'.
EDIT: Following is edited httpd.conf, there are no other config files. Output is deflated and then unzipped by client:
### Section 1: Global Environment
ServerTokens prod
CoreDumpDirectory /tmp
ServerRoot "/etc/httpd"
PidFile run/httpd.pid
Timeout 120
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 5
<IfModule prefork.c>
StartServers 20
MinSpareServers 5
MaxSpareServers 20
ServerLimit 256
MaxClients 256
MaxRequestsPerChild 4000
</IfModule>
<IfModule worker.c>
StartServers 2
MaxClients 150
MinSpareThreads 25
MaxSpareThreads 75
ThreadsPerChild 25
MaxRequestsPerChild 0
</IfModule>
Listen 80
#SOME LOAD MODULE CONFIG LINES REMOVED
LoadModule include_module modules/mod_include.so
LoadModule env_module modules/mod_env.so
LoadModule ext_filter_module modules/mod_ext_filter.so
LoadModule expires_module modules/mod_expires.so
LoadModule deflate_module modules/mod_deflate.so
LoadModule headers_module modules/mod_headers.so
LoadModule dav_module modules/mod_dav.so
LoadModule status_module modules/mod_status.so
LoadModule info_module modules/mod_info.so
LoadModule dav_fs_module modules/mod_dav_fs.so
LoadModule actions_module modules/mod_actions.so
LoadModule cache_module modules/mod_cache.so
LoadModule cgi_module modules/mod_cgi.so
Include conf.d/*.conf
ExtendedStatus Off
User apache
Group apache
### Section 2: 'Main' server configuration
ServerAdmin root#localhost
ServerName www.example.com:80
UseCanonicalName Off
DocumentRoot "/var/www/html"
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory "/var/www/html">
Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<IfModule mod_userdir.c>
UserDir disabled
</IfModule>
DirectoryIndex index.html index.html.var
AccessFileName .htaccess
<Files ~ "^.ht">
Order allow,deny
Deny from all
</Files>
TypesConfig /etc/mime.types
DefaultType text/plain
<IfModule mod_mime_magic.c>
MIMEMagicFile conf/magic
</IfModule>
HostnameLookups Off
#LOG CONFIG LINES REMOVED
ServerSignature Off
Alias /icons/ "/var/www/icons/"
<Directory "/var/www/icons">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<IfModule mod_dav_fs.c>
DAVLockDB /var/lib/dav/lockdb
</IfModule>
IndexOptions FancyIndexing VersionSort NameWidth=* HTMLTable Charset=UTF-8
#ICON CONFIG LINES REMOVED
ReadmeName README.html
HeaderName HEADER.html
IndexIgnore .??* *~ *# HEADER* README* RCS CVS *,v *,t
#LANGUAGE CONFIG LINES REMOVED
AddDefaultCharset UTF-8
AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz
AddType application/x-x509-ca-cert .crt
AddType application/x-pkcs7-crl .crl
AddHandler send-as-is asis
AddHandler type-map var
AddOutputFilter INCLUDES .html .xml
AddType application/x-httpd-php .php .html
Alias /error/ "/var/www/error/"
<IfModule mod_negotiation.c>
<IfModule mod_include.c>
<Directory "/var/www/error">
AllowOverride None
Options IncludesNoExec
AddOutputFilter Includes html
AddHandler type-map var
Order allow,deny
Allow from all
LanguagePriority en es de fr
ForceLanguagePriority Prefer Fallback
</Directory>
</IfModule>
</IfModule>
#BROWSER MATCH CONFIG LINES REMOVED
<Location /server-status>
SetHandler server-status
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Location>
<Location /server-info>
SetHandler server-info
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Location>
### Section 3: Virtual Hosts
NameVirtualHost *:80
FcgidMaxRequestLen 2000000
FcgidMinProcessesPerClass 5
FcgidIdleTimeout 18000
FcgidIOTimeout 60
TraceEnable Off
SetEnvIf User-Agent ".*MSIE.*" ISIE true
<VirtualHost *:80>
ServerName www.example.com
UseCanonicalName off
DocumentRoot /etc/httpd/www/examples/
DirectoryIndex index.html index.html.var
CheckSpelling on
CheckCaseOnly on
<Directory /etc/httpd/www/examples/>
Options Includes
AllowOverride None
Order Deny,Allow
Allow from all
Header Set Cache-Control "max-age=10"
ExpiresActive On
ExpiresByType text/html "access plus 10 seconds"
ExpiresByType image/gif A259200
ExpiresByType image/jpg A3600
ExpiresByType text/html A259200
ExpiresByType image/ico A259200
SetOutputFilter DEFLATE
</Directory>
<Directory />
Order Deny,Allow
Deny from All
</Directory>
#OTHER DIRECTORY CONFIG LINES REMOVED
</VirtualHost>
I had a problem similar to this recently, but using PHP. Problem was I had output buffering enabled. So as soon as my page reached some magical character limit, the output would be sent (because the buffer was full) and thus any headers set after that point would fail. Maybe you're having a similar issue? (Your buffer would be 8K characters)
Not sure if you're using vanilla HTML or some intermediate language...but I'd check all the settings of all the languages/technologies involved.
8000 characters is the definition of MAX_STRING_LEN in the Apache source code