Link to home
Create AccountLog in
Networking Protocols

Networking Protocols

--

Questions

--

Followers

Top Experts

Avatar of BRIDGEDIVISION
BRIDGEDIVISION🇺🇸

why are SMB file timestamps different between ftp & explorer
This is very strange to me and I'm not sure if I can explain it perfectly, but I'll try.

I have a network camera that regularly writes a video file out to a shared folder on my FreeNAS server using SMB protocol. If I view the file list with Windows explorer (Vista 64) all of the file stamps are exactly 5 hours 'earlier' than if I use ftp to list them.
If I use Windows Explorer and type in the ftp address where the files are located, then they all display with the correct time/date!

I have checked and re-checked the obvious.  The time on the NAS and the IP camera are correct. In fact, when I open a video (with wrong time stamp) the time imprinted on the video is the correct time.

Also, if I change the configuration in the camera to write out the files using FTP instead, then all of the time stamps show to be correct using Windows Explorer.

I spoke to my camera manufacturer and she stated that the SAMBA protocol was based on GMT (GMT +0) and she said there will always be a -5 hour difference for me.  This makes no sense to me.

I've included a screen shot that shows the listing in FTP and Explorer.  The listing for FTP is the correct times.
timestamp.JPG

Zero AI Policy

We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.


Avatar of btassurebtassure🇬🇧

I suspect that the FTP server software in your NAS box is somehow configured differently to the Samba server in terms of its timezone or something. Perhaps the Samba share is getting its time from the software clock which has adjusted for timezone changes while the FTP server is getting it from the hardware clock which will be UTC (same time as GMT but has a slightly different set up).

Avatar of BRIDGEDIVISIONBRIDGEDIVISION🇺🇸

ASKER

The Samba protocol settings and FTP protocol settings have been checked many times by me and neither have any adjustment for timezone or anything of that nature.   I also re-checked the time zone setting on my FreeNAS server and it is set to my time zone.

Avatar of giltjrgiltjr🇺🇸

Can you set a timezone on the camera?

My initial guess (which is normally wrong) is that the camera has no timezone and the time is set to your local time.  When it sends the file to the NAS box using SAMBA, the NAS box is assuming the time sent by the camera is GMT (the camera support person was correct, SAMBA timestamps are supposed to be GMT).  Since the camera is actually using local, the NAS box subtracts 5 hours (since your local time is now GMT-5) and thus you are 5 hours off.

Reward 1Reward 2Reward 3Reward 4Reward 5Reward 6

EARN REWARDS FOR ASKING, ANSWERING, AND MORE.

Earn free swag for participating on the platform.


Avatar of BRIDGEDIVISIONBRIDGEDIVISION🇺🇸

ASKER

The camera actually has a timezone setting, which I initially set (and re-checked).  Oddly enough, the live view of the camera, which I have the time imprinted on the image, is correct.  It's the file that is being written out to my NAS that has the wrong time stamp on it.
Another peice of the puzzle I've recently discovered.  If I change the way the files are written to the NAS (now by writing directly to a NAS Share from the camera) and change it to ftp the files over to the NAS folder, then the time is correct when I list them via Windows Explorer and then 5 hours off if I view the file listings via FTP.  In summary, the exact opposite is happening!
This is my temporary 'workaround' since I almost always view my files using Windows Explorer, but I'm still holding out for someone smart enough to figure out what is going on.

Avatar of giltjrgiltjr🇺🇸

If you copy a file from your local computer to the NAS box using SMB does it have the correct time?

What NAS and Camera are you using?

It really sounds like one of them is using the incorrect file, yes I know that is obvious.

Avatar of BRIDGEDIVISIONBRIDGEDIVISION🇺🇸

ASKER

If I copy a file from any of my PC's to the NAS the time stamp is ok.
I am using FreeNAS on a Dell Dimension 3100 and the camera is a Vivotek IP7142.  The camera's firmware allows for motion detect, when activated, to directly write to the NAS via FTP protocol, HTTP, or Samba.  I've checked with the camera people and they verified their settings (I gave them temp access to the camera).
Yes, the obvious does sound like a time zone issue but the fact that if I switch from FTP to Samba writes to NAS makes me now think something else.

Free T-shirt

Get a FREE t-shirt when you ask your first question.

We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.


ASKER CERTIFIED SOLUTION
Avatar of giltjrgiltjr🇺🇸

Link to home
membership
Log in or create a free account to see answer.
Signing up is free and takes 30 seconds. No credit card required.
Create Account

Avatar of giltjrgiltjr🇺🇸

I've look around and have found a few places where FreeNAS seems to have issues with timestamps.  I even saw your post on the FreeNAS support site.

Is your BIOS time set to local or GMT?

I have never used FreeNAS, but I know in Linux you can tell Linux that the BIOS clock is GMT or local time.  If your BIOS clock is set to local and you've told FreeNAS is it set to GMT (or the other way around) this would cause a problem with timestamps.

Avatar of BRIDGEDIVISIONBRIDGEDIVISION🇺🇸

ASKER

The answer led me to some other things (indirectly) that helped me solve my issue.
Networking Protocols

Networking Protocols

--

Questions

--

Followers

Top Experts

Networking software modules are interfaced with a framework implemented on the machine's operating system that implements the networking functionality of the operating system. The best known frameworks are the TCP/IP model and the OSI model. Systems typically do not use a single protocol to handle a transmission. Instead they use a set of cooperating protocols, sometimes called a protocol family or protocol suite.[9] Some of the best known protocol suites include: IPX/SPX, X.25, AX.25, AppleTalk and TCP/IP. Other protocols indirectly related to networking include the hypertext transfer protocol (HTTP) and its related technologies, Dynamic Host Configuration Protocol (DHCP), Domain Name Server (DNS) and other Internet protocols.