Tuesday, November 15, 2011

SharePoint 2010 File Name restrictions

SharePoint 2010 Content Naming rules:


Though the restrictions are documented at the above location, I wanted to take the bits from different blogs and make the information understandable to the general audience.

Folder Names and File Names
  1. Do not use - " # % & * :  <> ? \ / { } ~
  2. File names cannot be longer than 128 characters
  3. Do not use the period character consecutively in the middle of a file name. For example, "file..name.docx" is invalid.
  4. You cannot use the period character at the end of a file name
  5. You cannot start a file name with the period character
  6. Many other symbols are not recommended such as $^()-_=+[]`! (other international currency symbols and international symbols should be avoided in site names, but some are more acceptable in file names. Ascii is preferred when possible.
  7. File names and folder names may not end with the below. Becvause these are kind of reserved words:.files, _files , -Dateien , _fichiers , _bestanden , _file ,_archivos ,-filer,_tiedostot ,_pliki ,_soubory ,_elemei ,_arquivos ,
    _dosyalar ,_datoteke ,_fitxers,_failid
    ,_fails ,_bylos ,_fajlovi,_fitxategiak
Examples of Legal File Names
xyz.docx
abc_3454.doc
Long.Name.With.Dots.txt

Examples of illegal file names:
name%.wav.
multiple...dots.txt
lessthanfrst&last.mp3
questoin?.doc 

Site Naming rules 


  1. Not Allowed:   # { } % & " ~ + \ / : * ? " < >
  2. Avoid starting sites with an underscore (_) or with the period character.
  3. Site names can cause confusion and corruption if they have periods, apostrophes or commas
  4. They should not have consecutive periods or end with a period.
  5. You cannot use the period character at the end of a site name.
  6. Many other symbols are not recommended such as $^()-_=+[]`! (other international currency symbols and international symbols should be avoided in site names, but some are more acceptable in file names. Ascii is preferred when possible.
Examples of Illegal Site Names
Intranet/sites/AT & T
Intranet/sites/allow 10% me
Intranet/sites/_AUDI
Intranet/sites/#BMW
Intranet/sites/Carbs+Protiens

File and Folder name lengths

  1. Link list items are restricted to 256 characters and will truncate links to SharePoint documents (or anything else) with lengths longer than this.
  2. When storing files the structure and files (entire path including sites, folders, and file name) cannot add up to more than 260 characters or they will see an error message or form validation error with the explanation around the URL length.
  3. When using multi file upload interface: Make sure the total size of all your files is not greater than the upload limit set for your web application
upload size limits
To set the upload size to 200 megabytes, use the following syntax:
stsadm -o setproperty -pn max-file-post-size -pv 200

To view the current setting of the maximum file post size property, use the following syntax:
stsadm -o getproperty -pn max-file-post-size –url http://server_name

IIS Connection Timeouts

The default timeout for connections in IIS is 120 seconds (2 minutes). Depending on your maximum file size and how long it takes for the file to be uploaded, you may not need to change this setting. If, however, IIS is timing out when you upload large files, you can change this property to ensure that larger files can be uploaded successfully.

  1. Click Start, point to All Programs, point to Administrative Tools, and then click Internet Information Services (IIS) Manager.
  2. Right-click the virtual server you want to configure, and then click Properties.
  3. Click the Web Site tab.
  4. In the Connections section, in the Connection timeout box, type the number of seconds you want IIS to wait before timing out.
  5. Click OK.
Default chunk size for large files:

Sharepoint default chunk size is set to 5MB, this means that if a client tries to open a document of 50MB and the chunk size is 5MB, the document is divided and retrieved in 10 chunks. Each chunk will be loaded into the memory of both the WFE handling the request and the SQL Server
  1. stsadm -o setproperty -pn large-file-chunk-size -pv 1073741824
  2. IISReset

Thursday, November 10, 2011

The form cannot be submitted to the Web server

Issue definition:
Whenever you submit an infopath form "The form cannot be submitted to the Web server either because your computer is offline or because the host server is currently unavailable. If this problem persists, contact your network administrator"

Reason:

Ther are several reasons for this.
1. ISA server not configured properly
(or)
2. DNS not Configured Proerly
(or)
3. https ssl mappings not done properly using Alternate Access mappings

The above are the high level reasons for this issue. But, In our case, we deleted the root site (http://servername/) by mistake and this issue started bugging. InfoPath needs this root site to host the Infopath applications. When the form is actually published, SharePoint marks this location as the host.

Fix:


Create a root site. Below are the steps:
1. Access the SharePoint Central administratoin
2. Click on the 'Application Management' tab
3. Click on 'Define manged Paths'
4. in the Path field, enter "/"
5. select 'explicit inclusion' from the drop down and 'OK'