Problem with Reload

  • Hello

    I have a problem since I upgraded my samba server

    Now, Notepad++ detect too many reload from file which have not changed. Can you explain me how Notepad++ detect a change and want to reload the file ?

    Thank you and regards
    Philippe RITTER

  • Referencing this section of the code there can be a few things which cause a reload.

    1. The readonly flag has changed
    2. The timestamp is not the same
    3. I guess it is also possible that it might think the file gets deleted and the reappears. This would depend on how PathFileExists() handles networked files.

  • Ok, thank you for this information.

    But this doesn’t give me any help to understand the problem. Can I define some debug somewhere to catch why I get this reload on networked files on samba server ?
    Thank you and regards

  • Can I define some debug somewhere to catch why I get this reload on networked files on samba server ?

    Not as far as I know.

  • Hello @Philippe-E.-Ritter,

    don’t know if this is way you want to go but you could use network tracing tools (like wireshark or tcpdump) to see
    what is going on. Maybe this gives you an idea what happens?
    May I ask you which samba version on which which operating system you use?


  • Hello Claudia
    I have tried to get more debug on samba side, but doesn’t help very much.
    wireshark or tcpdump wouldn’t help either I think.
    Maybe I can try using procmon on Windows size to see what appends ?
    I’m using samba on Debian Jessie 8.4. Samba is release 4.1.17

    Thank you and regards

  • Could it be something related to this bug?

  • Thank you, but I don’t think so. This bug is related to libsmbclient, the client. My problem is with the server.
    Thank you and regards

  • Hello Philippe,

    today I updated my debian server to jessie release.
    Samba is also 4.1.17.
    Up 'til now it is running since 3 hours without any reload request shown.

    Maybe I can try using procmon on Windows size to see what appends ?

    Atleast it could give an indication why npp think it has to reload.
    I would define a path filter with relation ends.with and value of your file.
    And when you get the first reload request, which should be confirmed,
    check the IRP_MJ_QUERY_INFORMATION operation details of that file
    with previous informations.

    It will show informations like

    Type: QueryBasicInformationFile
    CreationTime: 07.04.2016 23:48:21
    LastAccessTime: 07.04.2016 23:48:21
    LastWriteTime: 07.04.2016 23:48:33
    ChangeTime: 07.04.2016 23:48:33
    FileAttributes: N


  • Hello Claudia,

    Thank you. I tried what you said, but this doesn’t give me more information. I see always the same time on each new QueryBasicInformationFile I look at, but Notepad++ still think something as changed.
    I found something helping to reproduce this problem, is just by letting a windows explorer opened on the folder where your file is stored. Can you tried this also in your environment ?
    Thank you and regards

  • Hello Philippe,

    I did, since 3 hours, and I will keep it open until shift ends, but didn’t get any issue yet.
    Well, the first 3 hours it was opened but minimized, now I will try with explorer being really open as a window.

    Hmmm, you are saying that this started happening after upgrading samba, could it be that other parts (hard- or software)
    was upgraded as well?


  • Hello Claudia,

    I think my problem is now solved.

    With the upgrade of Samba, I got many issues. Trying to resolve them, I added this to the smb.conf :
    dos filetime resolution = Yes

    Since I removed it, I didn’t get any reload in Notepad++

    Thank you for all your helping.

    Continue this good job!

  • Hello Phillipe,

    good job - I can confirm that this setting could be the cause of the problem.
    Can be checked by windows explorer easily.
    Right click on properties of a sambe file opened in npp. Notice the filestamp.
    Close dialog and again
    Right click on properties of the same file -> filestamp changed by 1 second. (not always but often)

    The interesting about this particular settings is that it was introduced to fix a quirk in windows to get
    the information that a file has changed - now it becomes the cause of a issue. ;-)


  • This is an unsolved problem… =[ Frankly, I don’t know what can be done to resolve this situation. I have already searched in many forums what can be done, but this set with a network share (samba, SMB) and Notepad ++ is problematic. As reported, the problem with constant file reloading makes it impossible to use Notepad ++ reliably and, especially, the use of bookmarks. Note that other code editor do not have the same problem even using the same network share. I would love to know what can be done. I’ve tried everything regarding the configuration of Notepad ++ and Samba, but I haven’t been successful so far.

    NOTE: Realize that I cannot do without the detection of changes (with warning) in files, as I work with several open source editors at the same time and this is a very big risk for me.

    Thanks friends! =D

Log in to reply