The orientational behavior of a smectic-A liquid crystal (4-cyano-4′-octylbiphenyl, 8CB) confined between mica surfaces as well as between silica surfaces with a nanometer scale thickness was investigated by synchrotron X-ray diffraction measurement. The crystallographic axes of two confining mica sheets were adjusted parallel to each other to induce the preferential orientation of 8CB molecules along their crystallographic axis. The silica surfaces, which were hydrophilic and amorphous and had nanometer level smoothness, were prepared on mica surfaces using a sputtering technique. The X-ray diffraction measurement revealed that the 8CB molecules, confined between mica surfaces (DHW = 1.7 nm) and between silica surfaces (DHW = ca. 2 nm), took a planar orientation (oriented its long axis parallel to the surface) and formed a lamellar structure. However, the in-plane orientation of the confined 8CB changed depending on the confining surfaces. The lamellar axis of the 8CB confined between mica surfaces uniaxially oriented most probably due to the preferential alignment of its long axis along the principal crystallographic a-axis of the mica. On the other hand, 8CB between the silica surfaces formed lamellar domains in which the lamellar axis of 8CB omnidirectionally oriented in-plane. The effect of the shear on the orientation of the nano-confined 8CB was also investigated. The lamellar axis, corresponding to the long axis of the 8CB molecules confined between the mica surfaces, rotated only ca. 3 degrees within the plane parallel to the surface by perpendicularly applying shear to the axis. The lamellar axis of the 8CB molecules between the silica surfaces showed no noticeable change by applying the shear. These results indicated that the effect of shear to align the 8CB molecules was significantly suppressed due to the confinement effect which significantly reduces the mobility of molecules as well as the alignment effect along the crystallographic axis in the case of mica. We also observed a change in the orientation of nano-confined 8CB after shear treatment at large D (= 3.3 μm).