Arduino nano error while uploading the sketch - arduino-nano

I got this error code. what should I do?
I will be glad if you help me 😀
Arduino: 1.8.18 (Windows 10), Board: "Arduino Nano, ATmega328P"
Sketch uses 1860 bytes (6%) of program storage space. Maximum is 30720 bytes.
Global variables use 186 bytes (9%) of dynamic memory, leaving 1862 bytes for local variables. Maximum is 2048 bytes.
avrdude: ser_open(): can't open device "\.\COM7": Eri�im engellendi.
Problem uploading to board. See https://support.arduino.cc/hc/en-us/sections/360003198300 for suggestions.
An error occurred while uploading the sketch
Exception in thread "Thread-129" java.util.ConcurrentModificationException
at java.util.LinkedList$LLSpliterator.forEachRemaining(LinkedList.java:1239)
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)
at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
at java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:151)
at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:174)
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:418)
at cc.arduino.contributions.libraries.LibrariesIndexer.rescanLibraries(LibrariesIndexer.java:169)
at processing.app.BaseNoGui.onBoardOrPortChange(BaseNoGui.java:681)
at processing.app.Base.onBoardOrPortChange(Base.java:1345)
at processing.app.Editor$UploadHandler.run(Editor.java:2097)
at java.lang.Thread.run(Thread.java:748)
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

Related

Booting kernel failed : Invalid argument ( Ubuntu installing)

So I tried installing "ubuntu-18.04.4" which is located in Desktop, with VirtualBox 16.1. When I hit the start button it loads a bit that purple page then shows this error (couldn't take a screenshot) :
EDD: Error 0c00 reading sector 995464.
EDD: Error 0c00 reading sector 999930.
EDD: Error 0c00 reading sector 999931.
EDD: Error 0c00 reading sector 1021411.
Booting kernel failed: Invalid argument
I tried disabling windows Secure Boot but the problem remains.
I have Windows10 64bits and reserved 10GB for Ubuntu.Here's a screenshot of other configurations :
Thanks a lot!

Is setting the linux memory to unlimit will have an adverse effect?

I am running MPI job in linux server. I got error:
--------------------------------------------------------------------------
The OpenFabrics (openib) BTL failed to initialize while trying to
allocate some locked memory. This typically can indicate that the
memlock limits are set too low. For most HPC installations, the
memlock limits should be set to "unlimited". The failure occured
here:
Local host: yw0431
OMPI source: ../../../../../ompi/mca/btl/openib/btl_openib_component.c:1216
Function: ompi_free_list_init_ex_new()
Device: mlx4_0
Memlock limit: 65536
You may need to consult with your system administrator to get this
problem fixed. This FAQ entry on the Open MPI web site may also be
helpful:
http://www.open-mpi.org/faq/?category=openfabrics#ib-locked-pages
--------------------------------------------------------------------------
--------------------------------------------------------------------------
WARNING: There was an error initializing an OpenFabrics device.
Local host: yw0431
Local device: mlx4_0
--------------------------------------------------------------------------
[yw0431:20193] 11 more processes have sent help message help-mpi-btl-openib.txt / init-fail-no-mem
[yw0431:20193] Set MCA parameter "orte_base_help_aggregate" to 0 to see all help / error messages
[yw0431:20193] 11 more processes have sent help message help-mpi-btl-openib.txt / error in device init
forrtl: error (78): process killed (SIGTERM)
it means that my linux server have locked memory with 65M, but my job needed more memory. I think 2G should be emough.
I have found a solution about ulimiting the memory:
ulimit -l unlimited
But i am worried that i will cause system crash or some bad things happen.
so can i set "ulimit -l umlimited"?
When you set ulimit as unlimited and your process starting using memory exhaustively then OOM killer will kill ur job for system stability,I would set the ulimit as 80 to 90% of RAM of instead of unlimited.

Segmentation fault when trying to execute recovered filesystem in a digital video tuner

Let me introduce where this thing comes from.
A few years ago I got a digital video tuner, which had a closed source version of Linux. The manufacturers of this device didn't want to share the source code of the OS, neither I was able to find it on internet. The SoC is a Celestial/Cavium CSM1800.
Doing some dubious things, I accidentally executed the update procedure and wiped the NAND flash. Luckily, I had dumped the contents of the mtd partitions (there are 2 mapped to this NAND flash, Kernel 3M and the rest is a JFFS2 partition).
This board has U-Boot loaded on another memory (a 1MB SPI), so "it wasn't totally bricked" because of the NAND wipe.
Back to the thing. I had a corrupt (dunno how it got corrupted) dump of the kernel, but after a lot of tinkering, I extracted the vmlinux (i.e. not gzip compressed) from the zImage. It seems the gzip unpack algorithm was bad, really weird.
After creating a new uImage using the vmlinux previously unpacked, I used the "fatload" command to load it and the thing booted, but of course it couldn't find the JFFS2 partition.
Then I tried writing the raw dump of the JFFS2 which I got from /dev/mtdblockX into the NAND, in the originally specified partition (after the 3M of the original kernel).
After booting, the kernel spit out a lot of errors concerning bad magics, empty flash, etc.
Well, after this I tried unpacking the JFFS2 in a Mint Virtual Machine, and I could extract the files. Since this tuner has an USB, I formatted a usb stick in ext2 and copied the files from the unpacked JFFS2 filesystem.
After crafting some bootargs to run from the usb stick instead of the NAND, I got the typical "Kernel panic - not syncing: Attempted to kill init!".
I quickly tried to specify the sh command in init via the bootargs. Same thing. So I downloaded a static linked binary version of busybox. I copied it to the /bin/ (where the original one resided), marked as executable, and tried again. This time, I got a shell!
The thing is, when I try to run ANY of the original applications, I got a "Segmentation fault" and nothing else.
Besides this, the /proc is not filled with anything, and I really don't have a clue why!
Other files, like text files or plain text files were OK, but im not discarding the possibility of a corrupted dump.
Finally, I tried to chroot to the unpacked JFFS2 in the Mint VM. Same "Segmentation fault" errors, but at least a core dump is created. I tried gdb-multiarch in that core dump, but only 2 frames appear, and since there are no symbols, nothing useful is shown there. (In fact, only the 2 frames addresses are only shown).
Some usefull (or not?) things:
binwalk of the vmlinux image
104288 0x19760 ASCII cpio archive (SVR4 with no CRC),
file name: "/dev", file name length: "0x00000005", file size:
"0x00000000"
104404 0x197D4 ASCII cpio archive (SVR4 with no CRC),
file name: "/dev/console", file name length: "0x0000000D", file size:
"0x00000000"
104528 0x19850 ASCII cpio archive (SVR4 with no CRC),
file name: "/root", file name length: "0x00000006", file size:
"0x00000000"
104644 0x198C4 ASCII cpio archive (SVR4 with no CRC),
file name: "TRAILER!!!", file name length: "0x0000000B", file size:
"0x00000000"
1856733 0x1C54DD Certificate in DER format (x509 v3),
header length: 4, sequence length: 1284
1856853 0x1C5555 Certificate in DER format (x509 v3),
header length: 4, sequence length: 1288
2597693 0x27A33D Certificate in DER format (x509 v3),
header length: 4, sequence length: 1292
2597797 0x27A3A5 Certificate in DER format (x509 v3),
header length: 4, sequence length: 1292
2598317 0x27A5AD Certificate in DER format (x509 v3),
header length: 4, sequence length: 5380
2598397 0x27A5FD Certificate in DER format (x509 v3),
header length: 4, sequence length: 5380
3292029 0x323B7D Certificate in DER format (x509 v3),
header length: 4, sequence length: 1292
3292033 0x323B81 Certificate in DER format (x509 v3),
header length: 4, sequence length: 1304
3292037 0x323B85 Certificate in DER format (x509 v3),
header length: 4, sequence length: 1308
3469469 0x34F09D Certificate in DER format (x509 v3),
header length: 4, sequence length: 3
3701960 0x387CC8 Linux kernel version "2.6.32.36-SDK-1.1
(ylei#software) (gcc version 4.4.1 (Sourcery G++ Lite 2010q1-202) ) #7
PREEMPT Wed Feb 15 14:12:59 CST 2012"
3705492 0x388A94 gzip compressed data, maximum
compression, from Unix, last modified: 2012-01-18 04:15:11
3930268 0x3BF89C CRC32 polynomial table, little endian
4692111 0x47988F Unix path:
/S70/S75/505V/F505/F707/F717/P8
readelf output of an executable file (rw_eeprom_byte). It's in spanish, but you could get the idea. http://pastebin.com/H0ZZcAaf (in pastebin so it keeps the spaces and it's more readeable).
uname:
Linux (none) 2.6.32.36-SDK-1.1 #7 PREEMPT Wed Feb 15 14:12:59 CST 2012
armv5tejl GNU/Linux
Original boot (with the original filesystem and kernel):
http://pastebin.com/YL2d2HYj
Any hints? Maybe another firmware that has the same SoC where I can extract the filesystem?
Thanks!
PS1: English is not my native language, so forgive any errors you might see.
PS2: I'm not an expert in Linux, and my strong area is programming embedded devices (withouth linux :P).

Tie System.map values to kernel addresses

I'm trying to boot a custom kernel on a BeagleBoneBlack. u-boot works, and loads stuff as follows:
U-Boot 2016.03 (Apr 26 2016 - 11:32:30 +0000)
Watchdog enabled
I2C: ready
DRAM: 512 MiB
MMC: OMAP SD/MMC: 0, OMAP SD/MMC: 1
*** Warning - bad CRC, using default environment
Net: <ethaddr> not set. Validating first E-fuse MAC
cpsw, usb_ether
Press SPACE to abort autoboot in 2 seconds
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1...
Found /boot/extlinux/extlinux.conf
Retrieving file: /boot/extlinux/extlinux.conf
278 bytes read in 39 ms (6.8 KiB/s)
1: Linux grsec
Retrieving file: /boot/initramfs-grsec
5875398 bytes read in 349 ms (16.1 MiB/s)
Retrieving file: /boot/vmlinuz-4.4.8-grsec
3140944 bytes read in 211 ms (14.2 MiB/s)
append: BOOT_IMAGE=/boot/vmlinuz-4.4.8-grsec modules=loop,squashfs,sd-mod,usb-storage modloop=/boot/modloop-grsec console=ttyO0,115200n8
Retrieving file: /boot/dtbs/am335x-boneblack.dtb
31516 bytes read in 426 ms (71.3 KiB/s)
Kernel image # 0x82000000 [ 0x000000 - 0x2fed50 ]
## Flattened Device Tree blob at 88000000
Booting using the fdt blob at 0x88000000
Loading Ramdisk to 8fa65000, end 8ffff6c6 ... OK
Loading Device Tree to 8fa5a000, end 8fa64b1b ... OK
Starting kernel ...
Everything looks good so far, I think. But the kernel fails to load. I can't get access to anything from the kernel with low level debugging enabled in the kernel options either.
I've attached a J-Link JTAG debugger and was hoping to trace through to the problem, but I'm having trouble tying the System.map through to the disassembly.
Here for example is the start of the System.Map:
00000000 t __vectors_start
00000024 A cpu_ca8_suspend_size
00000024 A cpu_v7_suspend_size
0000002c A cpu_ca9mp_suspend_size
00001000 t __stubs_start
00001004 t vector_rst
00001020 t vector_irq
000010a0 t vector_dabt
00001120 t vector_pabt
000011a0 t vector_und
00001220 t vector_addrexcptn
00001240 t vector_fiq
00001240 T vector_fiq_offset
80204000 A swapper_pg_dir
80208000 T _text
80208000 T stext
8020808c t __create_page_tables
8020813c t __turn_mmu_on_loc
80208148 t __fixup_smp
802081b0 t __fixup_smp_on_up
802081d4 t __fixup_pv_table
80208228 t __vet_atags
80208280 T __idmap_text_start
80208280 T __turn_mmu_on
80208280 T _stext
So taking __create_page_tables, I grep in the source code under ./arch/arm/kernel with:
.../arm/arm/kernel$ grep __create_page_tables -rn
Binary file head.o matches
head.S:128: bl __create_page_tables
head.S:180:__create_page_tables:
head.S:355:ENDPROC(__create_page_tables)
So we're looking for the following at the symbol address:
__create_page_tables:
pgtbl r4, r8 # page table address
But the disassembler shows something different at the address I'm translating too give the Kernel is loaded at 0x82000000:
How can I translate the kernel symbols to the debugger addresses?

Unable to start titan-server (Titan with Cassandra and Rexster)

I am trying to implement titan graph database on cassandra for one of my applications. As per documentation, I have downloaded and extracted titan-cassandra-0.3.2 and when it trying to run titan.sh with titan-server-rexster.xml andtitan-server-cassandra.properties as arguments I am facing below error:
In below stack trace it says "Cannot locate /opt/isv/app/pkgs/titan-cassandra-0.3.2/config/cassandra.yaml" but I do have that file in that location. Could anyone please help?
WARN org.apache.cassandra.utils.CLibrary - Unable to lock JVM memory (ENOMEM). This can result in part of the JVM being swapped out, especially with mmapped I/O enabled. Increase RLIMIT_MEMLOCK or run Cassandra as root.
72 [pool-1-thread-1] ERROR org.apache.cassandra.config.DatabaseDescriptor - Fatal configuration error
org.apache.cassandra.exceptions.ConfigurationException: Cannot locate /opt/isv/app/pkgs/titan-cassandra-0.3.2/config/cassandra.yaml
at org.apache.cassandra.config.DatabaseDescriptor.getStorageConfigURL(DatabaseDescriptor.java:113)
at org.apache.cassandra.config.DatabaseDescriptor.loadYaml(DatabaseDescriptor.java:130)
at org.apache.cassandra.config.DatabaseDescriptor.<clinit>(DatabaseDescriptor.java:122)
at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:150)
at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:366)
at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:409)
at com.thinkaurelius.titan.diskstorage.cassandra.embedded.CassandraDaemonWrapper$CassandraStarter.run(CassandraDaemonWrapper.java:64)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Cannot locate /opt/isv/app/pkgs/titan-cassandra-0.3.2/config/cassandra.yaml
Fatal configuration error; unable to start server. See log for stacktrace.
A complete walkthrough for ENOMEM is here
http://docs.datastax.com/en/archived/cassandra/2.0/cassandra/troubleshooting/trblshootInsufficientResources_r.html also do not forget
Basically edit /etc/security/limits.conf file appending the following
memlock unlimited
nofile 100000
nproc 32768
as unlimited
and then run sysctl -p

Resources