<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>DNS-313 | LogikDevelopment</title>
	<atom:link href="https://www.logikdev.com/tag/dns-313/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.logikdev.com</link>
	<description>&#34;Il n&#039;y a pas de problème, il n&#039;y a que des solutions. L&#039;esprit de l&#039;homme invente ensuite le problème.&#34; André Gide</description>
	<lastBuildDate>Tue, 25 Apr 2017 13:57:15 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.4</generator>
	<item>
		<title>CP2102 on DNS-323</title>
		<link>https://www.logikdev.com/2012/08/09/cp2102-on-dns-323/</link>
					<comments>https://www.logikdev.com/2012/08/09/cp2102-on-dns-323/#comments</comments>
		
		<dc:creator><![CDATA[smoreau]]></dc:creator>
		<pubDate>Thu, 09 Aug 2012 16:36:57 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[bash]]></category>
		<category><![CDATA[CP2101]]></category>
		<category><![CDATA[CP2102]]></category>
		<category><![CDATA[D-Link]]></category>
		<category><![CDATA[dmesg]]></category>
		<category><![CDATA[DNS-313]]></category>
		<category><![CDATA[shell]]></category>
		<category><![CDATA[Silicon Labs]]></category>
		<category><![CDATA[USB to RS232 converter]]></category>
		<guid isPermaLink="false">https://www.logikdev.com/?p=1834</guid>

					<description><![CDATA[<p>In one of my personal projects, I needed to connect and use a USB to RS232 (Serial) converter on my D-Link DNS-323. Weird requirements, I know. Anyway&#8230; 😐 Plenty of these converters exist out there, but I choose to go for a CP2102: Innocently, I first tried to compile the code source of this module [&#8230;]</p>
<p>The post <a href="https://www.logikdev.com/2012/08/09/cp2102-on-dns-323/">CP2102 on DNS-323</a> first appeared on <a href="https://www.logikdev.com">LogikDevelopment</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>In one of my personal projects, I needed to connect and use a USB to RS232 (Serial) converter on my D-Link DNS-323. Weird requirements, I know. Anyway&#8230; 😐<br />
Plenty of these converters exist out there, but I choose to go for a <a href="http://www.silabs.com/Support%20Documents/TechnicalDocs/cp2102.pdf" target="_blank"><strong>CP2102</strong></a>:</p>
<p><img decoding="async" class="aligncenter size-medium wp-image-1844" title="CP2102" src="https://www.logikdev.com/wp-content/uploads/2012/08/CP2102-300x125.jpg" alt="" width="300" height="125" srcset="https://www.logikdev.com/wp-content/uploads/2012/08/CP2102-300x125.jpg 300w, https://www.logikdev.com/wp-content/uploads/2012/08/CP2102.jpg 458w" sizes="(max-width: 300px) 100vw, 300px" /></p>
<p>Innocently, I first tried to compile the code source of this module which can be found on the following page:<br />
<a href="http://www.silabs.com/products/mcu/Pages/USBtoUARTBridgeVCPDrivers.aspx" target="_blank">http://www.silabs.com/products/mcu/Pages/USBtoUARTBridgeVCPDrivers.aspx</a></p>
<p>After a few painful and unsuccessful tries, I decided to look around for the already-compiled module. 😉<br />
While wondering why I didn&#8217;t think of that before, I used the instructions below to install the required modules on my NAS:</p>
<pre class="brush: bash; light: true; title: ; notranslate">
cd /mnt/HD_a2/ffp/lib/
mkdir modules
mkdir modules/2.6.12.6-arm1
cd modules/2.6.12.6-arm1
wget http://dev.skcserver.de/dns323/modules_v1.03/kernel/drivers/usb/serial/usbserial.ko
wget http://dev.skcserver.de/dns323/modules_v1.03/kernel/drivers/usb/serial/cp2101.ko
chmod 755 usbserial.ko
chmod 755 cp2101.ko
</pre>
<p>Once the modules are installed, the next step is to initialize them.<br />
I wrote the following script for this purpose so you can execute it anytime you need it:</p>
<pre class="brush: bash; title: ; notranslate">
#!/bin/sh

insmod /ffp/lib/modules/2.6.12.6-arm1/usbserial.ko
insmod /ffp/lib/modules/2.6.12.6-arm1/cp2101.ko
mknod /dev/ttyUSB0 c 188 0
chmod 0666 /dev/ttyUSB0
</pre>
<p>At this point in time, you should have your module initialized on your D-Link DNS-323.<br />
You can check the kernel ring buffer using the <strong>dmesg</strong> command to verify it loaded properly.<br />
This is a snapshot of what I have in my kernel ring buffer after I ran the script above:</p>
<pre class="brush: bash; light: true; title: ; notranslate">
usbcore: registered new driver usbserial
drivers/usb/serial/usb-serial.c: USB Serial support registered for Generic
usbcore: registered new driver usbserial_generic
drivers/usb/serial/usb-serial.c: USB Serial Driver core v2.0
drivers/usb/serial/usb-serial.c: USB Serial support registered for CP2101
CP2101 1-1:1.0: CP2101 converter detected
usb 1-1: reset full speed USB device using ehci_platform and address 5
usb 1-1: CP2101 converter now attached to ttyUSB0
usbcore: registered new driver CP2101
drivers/usb/serial/cp2101.c: Silicon Labs CP2101/CP2102 RS232 serial adaptor driver v0.04
</pre>
<p>Finally, you can test the communication with your USB to RS232 converter by connecting a LED between the RXD and 3V outputs and running the following script:</p>
<pre class="brush: bash; title: ; notranslate">
#!/bin/sh

while &#x5B; true ]
do
echo &quot;hello world!!!&quot; &gt; /dev/ttyUSB0
echo &quot;sent&quot;
sleep 1
done
</pre>
<p>If you see the LED blinking, it means you succeed! 😀</p><p>The post <a href="https://www.logikdev.com/2012/08/09/cp2102-on-dns-323/">CP2102 on DNS-323</a> first appeared on <a href="https://www.logikdev.com">LogikDevelopment</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://www.logikdev.com/2012/08/09/cp2102-on-dns-323/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
		<item>
		<title>Samba access problem with Mac OS X 10.6+</title>
		<link>https://www.logikdev.com/2011/12/13/samba-access-problem-with-mac-os-x-10-6/</link>
					<comments>https://www.logikdev.com/2011/12/13/samba-access-problem-with-mac-os-x-10-6/#respond</comments>
		
		<dc:creator><![CDATA[smoreau]]></dc:creator>
		<pubDate>Tue, 13 Dec 2011 21:31:15 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[D-Link]]></category>
		<category><![CDATA[DNS-313]]></category>
		<category><![CDATA[Mac OS X]]></category>
		<category><![CDATA[Samba]]></category>
		<category><![CDATA[security mode]]></category>
		<guid isPermaLink="false">https://www.logikdev.com/?p=1653</guid>

					<description><![CDATA[<p>This is a problem I encountered when I upgraded Mac OS X from the version 10.5 (Leopard) to 10.6 (Snow Leopard). One of my friend also got a similar problem when she upgraded to the version 10.7 (Lion). This issue was affecting the access to the network shares set up with Samba (version 3.0.24) on [&#8230;]</p>
<p>The post <a href="https://www.logikdev.com/2011/12/13/samba-access-problem-with-mac-os-x-10-6/">Samba access problem with Mac OS X 10.6+</a> first appeared on <a href="https://www.logikdev.com">LogikDevelopment</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>This is a problem I encountered when I upgraded Mac OS X from the version 10.5 (Leopard) to 10.6 (Snow Leopard). One of my friend also got a similar problem when she upgraded to the version 10.7 (Lion).<br />
This issue was affecting the access to the network shares set up with <strong>Samba</strong> (version 3.0.24) on my D-Link DNS-323. For some reason, I wasn&#8217;t able to authenticate on the shares as soon as I upgraded to Snow Leopard!</p>
<p>Here is the error message I was getting:<br />
<a href="https://www.logikdev.com/wp-content/uploads/2011/12/samba-access-problem.png"><img fetchpriority="high" decoding="async" src="https://www.logikdev.com/wp-content/uploads/2011/12/samba-access-problem-300x271.png" alt="" title="Samba authentication problem on Mac OS X" width="300" height="271" class="alignnone size-medium wp-image-1669" srcset="https://www.logikdev.com/wp-content/uploads/2011/12/samba-access-problem-300x271.png 300w, https://www.logikdev.com/wp-content/uploads/2011/12/samba-access-problem.png 438w" sizes="(max-width: 300px) 100vw, 300px" /></a></p>
<p>After browsing a few forums on the web, I finally found a solution. <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f642.png" alt="🙂" class="wp-smiley" style="height: 1em; max-height: 1em;" /><br />
I simply had to change the security mode in the Samba configuration file (<code>smb.conf</code>) to read:</p>
<pre class="brush: bash; light: true; title: ; notranslate">
security = USER
</pre>
<p>Note that this property can be found under the <code>[global]</code> section.</p>
<p>For more information about the Samba security mode, please read the following article by Jack Wallen:<br />
<a href="http://www.ghacks.net/2010/03/17/understanding-samba-security-modes/" title="Understanding Samba security modes" target="_blank">Understanding Samba security modes</a></p><p>The post <a href="https://www.logikdev.com/2011/12/13/samba-access-problem-with-mac-os-x-10-6/">Samba access problem with Mac OS X 10.6+</a> first appeared on <a href="https://www.logikdev.com">LogikDevelopment</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://www.logikdev.com/2011/12/13/samba-access-problem-with-mac-os-x-10-6/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Permissions ignored with Samba</title>
		<link>https://www.logikdev.com/2011/01/17/permissions-ignored-with-samba/</link>
					<comments>https://www.logikdev.com/2011/01/17/permissions-ignored-with-samba/#comments</comments>
		
		<dc:creator><![CDATA[smoreau]]></dc:creator>
		<pubDate>Mon, 17 Jan 2011 22:27:09 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[D-Link]]></category>
		<category><![CDATA[DNS-313]]></category>
		<category><![CDATA[Mac OS X]]></category>
		<category><![CDATA[permissions]]></category>
		<category><![CDATA[Samba]]></category>
		<category><![CDATA[unix extensions]]></category>
		<guid isPermaLink="false">https://www.logikdev.com/?p=998</guid>

					<description><![CDATA[<p>After the issue regarding the ntpd process, I encountered another problem with my D-Link DNS-313. This time it was about permissions problem using Samba. Because I have multiple user accounts sharing the same data, I added the following lines into the Samba configuration file (smb.conf): create mask = 0774 directory mask = 0775 force create [&#8230;]</p>
<p>The post <a href="https://www.logikdev.com/2011/01/17/permissions-ignored-with-samba/">Permissions ignored with Samba</a> first appeared on <a href="https://www.logikdev.com">LogikDevelopment</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>After the issue regarding the <a href="/2011/01/10/ntpd-process-on-dlink-dns313/">ntpd process</a>, I encountered another problem with my <a href="http://dlink.co.uk/cs/Satellite?c=Product_C&amp;childpagename=DLinkEurope-GB%2FDLProductCarouselMultiple&amp;cid=1197319418492&amp;p=1197318962342&amp;packedargs=ParentPageID%3D1197318962321%26TopLevelPageProduct%3DConsumer%26locale%3D1195806691854%26packedargs%3DProductParentID%253D1195808623796&amp;pagename=DLinkEurope-GB%2FDLWrapper"><strong>D-Link DNS-313</strong></a>. This time it was about permissions problem using <a href="http://en.wikipedia.org/wiki/Samba_(software)"><strong>Samba</strong></a>.</p>
<p>Because I have multiple user accounts sharing the same data, I added the following lines into the Samba configuration file (<code>smb.conf</code>):</p>
<pre class="brush: bash; light: true; title: ; notranslate">
create mask = 0774
directory mask  = 0775
force create mode = 0774
force directory mode = 0775
</pre>
<p>With these properties, a user will have the permission to read any files created by another user and will also be able to edit them if both users are part of the same group.</p>
<p>However, it appeared that these properties had been ignored by Samba! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f641.png" alt="🙁" class="wp-smiley" style="height: 1em; max-height: 1em;" /> Please note that the client was a Mac OS X 10.6.6 (Snow Leopard) and the Samba version on the NAS was 3.0.25a.</p>
<p>After some googling on the web, I found the following explanation on the <a href="http://forums.contribs.org/index.php?topic=40599.0">contribs.org forum</a>:</p>
<blockquote><p>
Samba 3.0.2x has the &#8216;unix extensions&#8217; option set to &#8216;on&#8217; by default. This allows Unix users who write to the Samba shares to set their own permissions bits. Mac OS X up until now has never attempted to do this, but from Leopard, any directory that gets created on a Samba share, get chmod&#8217;ed through this Samba extension.</p></blockquote>
<p>Alright, this is clear enough! This means that we have to set the &#8216;unix extensions&#8217; option to &#8216;no&#8217; in our Samba configuration file:</p>
<pre class="brush: bash; light: true; title: ; notranslate">
unix extensions = no
</pre>
<p>The problem should be gone after restarting Samba. <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f642.png" alt="🙂" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p><p>The post <a href="https://www.logikdev.com/2011/01/17/permissions-ignored-with-samba/">Permissions ignored with Samba</a> first appeared on <a href="https://www.logikdev.com">LogikDevelopment</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://www.logikdev.com/2011/01/17/permissions-ignored-with-samba/feed/</wfw:commentRss>
			<slash:comments>7</slash:comments>
		
		
			</item>
		<item>
		<title>ntpd process on D-Link DNS-313</title>
		<link>https://www.logikdev.com/2011/01/10/ntpd-process-on-dlink-dns313/</link>
					<comments>https://www.logikdev.com/2011/01/10/ntpd-process-on-dlink-dns313/#comments</comments>
		
		<dc:creator><![CDATA[smoreau]]></dc:creator>
		<pubDate>Mon, 10 Jan 2011 19:50:51 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[bash]]></category>
		<category><![CDATA[D-Link]]></category>
		<category><![CDATA[DNS-313]]></category>
		<category><![CDATA[DNS-323]]></category>
		<category><![CDATA[fun_plug]]></category>
		<category><![CDATA[NAS]]></category>
		<category><![CDATA[NTP]]></category>
		<category><![CDATA[ntpd]]></category>
		<category><![CDATA[shell]]></category>
		<guid isPermaLink="false">https://www.logikdev.com/?p=992</guid>

					<description><![CDATA[<p>During the configuration of a D-Link DNS-313 which is basically a NAS (Network-Attached Storage), I got a serious but easy-to-fix problem. 🙂 In order to get access to the box by command line, I installed the Fonz fun_plug. I then wanted to automatically synchronise the internal time with some NTP Pool Time Servers. But, for [&#8230;]</p>
<p>The post <a href="https://www.logikdev.com/2011/01/10/ntpd-process-on-dlink-dns313/">ntpd process on D-Link DNS-313</a> first appeared on <a href="https://www.logikdev.com">LogikDevelopment</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>During the configuration of a <strong><a href="http://dlink.co.uk/cs/Satellite?c=Product_C&amp;childpagename=DLinkEurope-GB%2FDLProductCarouselMultiple&amp;cid=1197319418492&amp;p=1197318962342&amp;packedargs=ParentPageID%3D1197318962321%26TopLevelPageProduct%3DConsumer%26locale%3D1195806691854%26packedargs%3DProductParentID%253D1195808623796&amp;pagename=DLinkEurope-GB%2FDLWrapper">D-Link DNS-313</a></strong> which is basically a NAS (<a href="http://en.wikipedia.org/wiki/Network-attached_storage">Network-Attached Storage</a>), I got a serious but easy-to-fix problem. <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f642.png" alt="🙂" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>
<p>In order to get access to the box by command line, I installed the <a href="http://www.inreto.de/dns323/fun-plug/0.5/">Fonz fun_plug</a>. I then wanted to automatically synchronise the internal time with some <a href="http://support.ntp.org/bin/view/Servers/NTPPoolServers">NTP Pool Time Servers</a>. But, for some reason, the version of the <code>ntpd</code> process provided with fun_plug is completely freezing the NAS. I wasn&#8217;t able to find the root cause of it, trust me, I tried everything I could think of!<br />
Please also note that the same process is working perfectly fine on his brother, the <strong><a href="http://dlink.co.uk/cs/Satellite?c=Product_C&amp;childpagename=DLinkEurope-GB%2FDLProductCarouselMultiple&amp;cid=1197319419183&amp;p=1197318962342&amp;packedargs=ParentPageID%3D1197318962321%26TopLevelPageProduct%3DConsumer%26locale%3D1195806691854%26packedargs%3DProductParentID%253D1195808623796&amp;pagename=DLinkEurope-GB%2FDLWrapper">D-Link DNS-323</a></strong>. As I said, I can&#8217;t explain why&#8230; <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f644.png" alt="🙄" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>
<p>But there is a good news! The <code>ntpd</code> process is actually part of the D-Link DNS-313 firmware. And it is working fine! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f600.png" alt="😀" class="wp-smiley" style="height: 1em; max-height: 1em;" /> After double-checking, this process is however NOT part of the D-Link DNS-323 firmware. Why is that? Maybe D-Link got complaints from DNS-313 users and fixed it? Who knows&#8230;</p>
<p>Anyway, in order to get the <code>ntpd</code> process to work on the D-Link DNS-313, you need to replace the content of your <code>ntpd</code> startup script (<code>/ffp/start/ntpd.sh</code>) by the one below:</p>
<pre class="brush: bash; title: ; notranslate">
#!/ffp/bin/sh

# PROVIDE: ntpd
# REQUIRE: SERVERS
# BEFORE: LOGIN

. /ffp/etc/ffp.subr

name=&quot;ntpd&quot;
command=&quot;/usr/sbin/ntpd&quot;
ntpd_flags=&quot;-f /ffp/etc/ntpd.conf&quot;
required_files=&quot;/ffp/etc/ntpd.conf&quot;
start_cmd=&quot;ntpd_start&quot;

ntpd_start()
{
    # remove rtc and daylight cron jobs
    crontab -l | grep -vw '/usr/sbin/daylight' | grep -vw '/usr/sbin/rtc' | crontab -

    proc_start $command
}

run_rc_command &quot;$1&quot;
</pre><p>The post <a href="https://www.logikdev.com/2011/01/10/ntpd-process-on-dlink-dns313/">ntpd process on D-Link DNS-313</a> first appeared on <a href="https://www.logikdev.com">LogikDevelopment</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://www.logikdev.com/2011/01/10/ntpd-process-on-dlink-dns313/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
	</channel>
</rss>
