smb

Accessing SMB2.1 or SMB3 share from java?

旧巷老猫 提交于 2019-11-29 15:11:48
问题 As Windows 2012R2 no longer supports the SMB1 protocol without some registry hacks has any had any success working with SMB shares in Java where only SMB2.1 or SMB3 are supported? the JCIFS library is apparently SMB1 only so it is out. I see that Microsoft have a Java library for Azure but this appears to be utilising services rather than SMB. 回答1: I found this package that can work with SMB2 and SMB3, named smbj Take a look at this: https://github.com/hierynomus/smbj 回答2: Expanding on

定时任务之crontab命令

你。 提交于 2019-11-29 13:57:04
简介 crontab用于设置周期性被执行的命令 Linux系统中Linux调动工作分为两大类:   1、系统执行的工作:系统周期性所要执行的工作,如备份系统数据、清理缓存   2、个人执行的工作:某个用户定期要做的工作,例如每隔10分钟检查邮件服务器是否有新信,这些工作可由每个用户自行设置 /etc/crtontab   系统调度的任务一般存放在/etc/crontab这个文件下,里面存放了一些系统运行的调度程序,通过命令cat crontab查看   这些任务会在系统运行起来自动调用 /var/spool/cron   每个用户都会生成自动生成一个自己的crontab文件,一般位于/var/spool/cron目录下   执行命令crontab -r 就会删除当前用户的crontab文件。例如你切换到suifeng账号下,执行了该命令,那么/var/spool/cron/suifeng文件就会删除,如果要创建该文件只需要用crontab -e命令即可。   注意,普通用户一般没有权限访问/var/spool/cron /etc/crontab.deny文件与/etc/crontab.allow文件   1、分别表示不能使用crontab命令的用户、以及能够使用crontab命令的用户   2、两个文件同时存在crontab.allow文件优先   3

Does iOS support file operations via SMB?

那年仲夏 提交于 2019-11-29 09:49:39
Does iOS (or iPhone OS) support file operations via SMB network shares? If so, are there any documents about how to do this? Don't have tested yet but this might help: http://38leinad.wordpress.com/2011/03/23/windows-filesharing-library-for-ios/ smile.al.d.way I thought I made it work between macbook and my iPhone simulator however it never worked for folders shared on windows machine .. please refer to a separate question I have posted - Using NSNetService class to make an SMB tcp ip connection to a folder shared on windows machine - with steps I have taken ... Not sure about SMB, but I was

docker-compose部署elk

对着背影说爱祢 提交于 2019-11-29 06:18:54
version: "3.4" services: es-master: container_name: es-master image: elasticsearch:7.3.1 restart: always ports: - 19200:9200 - 19300:9300 environment: - node.name=es-master - cluster.initial_master_nodes=es-master volumes: - "/home/smb/data/es/master:/usr/share/elasticsearch/data" - "/home/smb/config/es/master/elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml" - "/home/smb/logs/es/master:/user/share/elasticsearch/logs" networks: - smb es-node1: container_name: es-node1 image: elasticsearch:7.3.1 restart: always volumes: - "/home/smb/data/es/node1:/usr/share/elasticsearch/data

windows CIFS sabma协议识别

穿精又带淫゛_ 提交于 2019-11-28 20:30:26
windows CIFS sabma协议识别 https://www.cnblogs.com/tcicy/p/9992871.html公司的一个共享服务器就是 win2003的 mount 的时候 需要使用vers=1.0 的参数 win2019 的操作系统 需要使用 cifs1.0 安装才可以用. 今天在linux上搭建了CIFS协议,使用sabma4.7.0版本。 通过smbstatus可以查看smb软件的版本 通过/bin/smbstatus -d 0可以查看目前正连接的客户端。 问题来了:不知道这个smb到底支持哪些SMB协议,目前SMB的版本有1.X 2.02 2.1 3.0 3.0.2 3.1.1 至少网上没有查询到方法或者文档。虽然知道samba4.7.0肯定支持SMB全协议。 在使用wireshark进行协议抓包的时候,发现了这个问题的解决办法: wireshark开始抓包 打开"我的电脑",输入\\1.1.1.1 然后看到wireshark中有NEGTIATE Request和NEGTIATE Response的内容,一般在两台服务器之间的NEGTIATE Response字段中Dialect数据是最终协商完的SMB版本。 从上图可以看到 1.wireshark中标识为SMB2版本,看上去是错误,实际上Microsoft就是这样规定的。只要非SMB1.X版本

What is Zone Identifier? [closed]

杀马特。学长 韩版系。学妹 提交于 2019-11-28 18:05:38
I often saw some files which named 'blabla.exe:Zone.Identifier' monitoring I/O with Process Monitor. The files could be seen network-drive. What is Zone.Identifier? What does the colon mean in the filename. Is the colon related the file's extended attributes? Zabba The text after the colon is an identifier for an "Alternate Data Stream". ADS is used to store meta-information about the file. For example, the Zone identifier stores whether the file was downloaded from the internet. Some specific info: About URL Security Zones , Zone.Identifier Stream Name Best is to google around for more

像修改本机代码一样修改远端服务器的PHP网站

半腔热情 提交于 2019-11-28 15:24:11
映射vps目录到自己电脑的摸索记录 最近拿discuz做了一个网站,需要修改模板文件之类的,还需要调试微信和QQ登陆的接口。都是些位置零散的小修改,但是有些需要在线上才能调试(QQ微信的oauth登陆,各种插件)。为了方便开发,我打算在阿里云的centos服务器上安装一个vpn和smb服务,然后在我的开发机上连接VPN并创建网络磁盘映射。 实验环境: 服务端 阿里云centos7服务器 客户端 普通的windows 10操作系统 实验过程: 1、PPTP VPN(不稳定因而丢弃,您可以跳过pptp,直接使用smba+openvpn达到效果) 找了一个一键安装pptpd vpn的脚本 默认配置就可以让pptpd跑通 中间忘记了阿里云的centos7默认使用的是firewalld这个服务的防火墙,后来 systemctl stop firewalld systemctl disable firewalld 关闭了防火墙,仅用阿里云轻量级服务器的防火墙开通相应端口。这里找到firewalld服务花了点时间。pptp连接建立 2、在centos7上安装smba服务 smba服务是用来在linux操作系统上共享文件或者目录到windows网络的服务。也就是在linux上安装了之后可以指定某些文件夹共享到局域网

Does iOS support file operations via SMB?

末鹿安然 提交于 2019-11-28 03:07:20
问题 Does iOS (or iPhone OS) support file operations via SMB network shares? If so, are there any documents about how to do this? 回答1: Don't have tested yet but this might help: http://38leinad.wordpress.com/2011/03/23/windows-filesharing-library-for-ios/ 回答2: I thought I made it work between macbook and my iPhone simulator however it never worked for folders shared on windows machine .. please refer to a separate question I have posted - Using NSNetService class to make an SMB tcp ip connection

How to copy file from smb share to local drive using jcifs in Java?

强颜欢笑 提交于 2019-11-28 01:14:00
Could anybody help me to copy file from shared folder to local drive? My code is: import jcifs.smb.NtlmPasswordAuthentication; import jcifs.smb.SmbFile; import jcifs.smb.SmbFileInputStream; import jcifs.smb.SmbFileOutputStream;; public class smb { /** * @param args * @throws IOException */ public static void main(String[] args) throws IOException { // TODO Auto-generated method stub String urlToBackUpFile = "smb://ip/backup$/test.txt"; System.out.println("smb folder of source file" + urlToBackUpFile); NtlmPasswordAuthentication auth = new NtlmPasswordAuthentication(null, "login", "pass");

Windows file share: why sometimes newly created files aren't visible for some period of time?

久未见 提交于 2019-11-27 19:04:25
We were faced with very strange issue that made us crazy. Sometimes newly created files on our File Share PC were "absent" for some period of time. To reproduce a problem you should have at least two computers, call them alpha and beta . Create file share on beta PC ( \\beta\share\bug ) and run this PowerShell script from alpha PC: param( $sharePath="\\beta\share\bug" ) $sharePC = ($sharePath -split '\\')[2] $session = New-PSSession -ComputerName $sharePC $counter = 0 while ($true) { $fileName = $sharePath + "\$counter.txt" Invoke-Command -Session $session -ScriptBlock { param( $fileName ) ""