问:
Enabling Hadoop Namenode HA in Apache ambari using Bigtop
I Cloned the Bigtop code from Github, built RPMS, and installed the Hadoop cluster using Ambari. The Hadoop cluster had 3 nodes. When the name node HA is enabled from Ambari, the services do not start in step 7( Start Components  ), so forward steps cannot be performed. Ambari agent throws some errors when it comes to step 7.

```<code>> Ambari-2.7.5
> Hadoop-3.3.4
> Zookeeper-3.5.9
> Linux server: Centos-7
</code>```

In Ambari agent i am getting the following the error in the log.

```<code>> INFO 2022-12-05 13:58:37,440 __init__.py:82 - Event from server at /user/ (correlation_id=227): {u'status': u'OK'}
> ERROR 2022-12-05 13:58:37,704 alert_ha_namenode_health.py:185 - [Alert] NameNode High Availability Health on instance-5 fails:
> Traceback (most recent call last):
> File "/var/lib/ambari-agent/cache/common-services/HDFS/2.1.0.2.0/package/alerts/alert_ha_namenode_health.py", line 175, in execute
> state_response = get_jmx(jmx_uri, connection_timeout)
> File "/var/lib/ambari-agent/cache/common-services/HDFS/2.1.0.2.0/package/alerts/alert_ha_namenode_health.py", line 206, in get_jmx
> response = urllib2.urlopen(query, timeout=connection_timeout)
> File "/usr/lib64/python2.7/urllib2.py", line 154, in urlopen
> return opener.open(url, data, timeout)
> File "/usr/lib64/python2.7/urllib2.py", line 431, in open
> response = self._open(req, data)
> File "/usr/lib64/python2.7/urllib2.py", line 449, in _open
>     '_open', req)
> File "/usr/lib64/python2.7/urllib2.py", line 409, in _call_chain
> result = func(*args)
> File "/usr/lib64/python2.7/urllib2.py", line 1244, in http_open
> return self.do_open(httplib.HTTPConnection, req)
> File "/usr/lib64/python2.7/urllib2.py", line 1214, in do_open
> raise URLError(err)
> URLError: <urlopen error [Errno 111] Connection refused>
</code>```

Ambari UI While trying to Enable HA

Namenode Log

```<code>> 2022-12-08 07:12:52,477 INFO  namenode.FSEditLog
> (FSEditLog.java:printStatistics(794)) - Number of transactions: 168
> Total time for transactions(ms): 19 Number of transactions batched in
> Syncs: 4638 Number of syncs: 143 SyncTimes(ms): 268 2022-12-08
> 07:12:52,481 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/38b9c9dc549394c67f819f03f02ef67c/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,481 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/54a35f5c02b78671aa3cb1a555d4f13d/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,486 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/65daedd407be5de5db0a6df509451aac/recovered.edits/25.seqid is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,489 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.STATS/2b8248a14c2e38b71595200ae6cb6e9c/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,489 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/90de5ae3b5daaf334553cb73d3cffe96/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,495 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/8d944f63f2eec5d95fbf16a45eda13d1/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,496 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/hbase/meta/1588230740/recovered.edits/1300.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,526 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/611f59084c88307ee011a520a00cf1eb/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,529 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/5dbe5b39d39be33e7c549caab73352ba/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,530 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/ba0d8e224fd563575687aab2afa1de39/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,534 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/2760ea047005151d035b988ef5a526f5/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,536 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/f8129cf7b0102dabf7ec9683513c1feb/recovered.edits/25.seqid is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,566 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.TASK/8667cc4454dd118504027c07ed8c150f/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,567 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/a023890792b51c1551471baaf3f385f5/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,567 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/67a1e7ae67d76782a2adbaae3b2687a9/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,582 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/b59bdfcad8908003169571d01f135278/recovered.edits/22.seqid is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,583 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/4c62db7bf1c479ede323e53d21d9a41f/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,583 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/3ea53d95ec4227d5f5fc24c5e79a801f/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,583 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/4604f896ccf933960a21a4f81edfa23f/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,584 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/f0030813232204d5165972d0b99e4a82/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,586 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/0533eb20acb1aa3233403c30dcff05a6/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,612 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/303cb7d7b8ce11cbc4df9bc83e122898/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,615 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/7a766993e99daeb64e3d2219ca8c9427/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,616 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/4a3abf63944203c5020a3f2ef5749c44/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,629 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/6be9c041387ca418f6c35f91135a3b7e/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,629 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/210c8496760d4754384b27bf3b45c072/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,655 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/df5d0ccbe8941453697c89984985ecd1/recovered.edits/22.seqid is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,655 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.CATALOG/ee1348d962c03994578d6bc8f0389831/recovered.edits/43.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,655 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/afa9666d2296f1d7c8629bbc7fc84073/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,662 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/52b00f10bbcede600fe5f434b34629e9/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,665 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/a3fa94f77440b13d37602dace771aa7d/recovered.edits/29.seqid is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,678 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/6c02cf70d5286b712c89a5f136167476/recovered.edits/26.seqid is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,679 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/526cacd3866c13e1c229baa123108783/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,683 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.SEQUENCE/9db3f45bdef2439677f1d7cfed837e24/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,705 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/498c428ad17956df4843f78642957840/recovered.edits/23.seqid is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,706 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/hbase/namespace/bb7e9d3268a1cdf39f49426f0014cf37/recovered.edits/33.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,708 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.MUTEX/c7ec76e62616a4da4f8b81230921dd78/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,709 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/6f89e061764c1ec1a64b608e6e18c62c/recovered.edits/22.seqid is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,710 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.FUNCTION/85740d4c80415117ddf7c8321cabd250/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,714 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/a26508adf2909c8bca5c4f02985bb096/recovered.edits/25.seqid is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,725 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/049bc3d9d7d676e72af6e31163db4364/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,725 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/c96562dd2509624dfe49f1586652e083/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,726 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/65b3fbf36173133b8b368e7fa7b37306/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,727 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/58986e109c517c6893f00bd9c749144a/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,730 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/11de2f3f2cc497467a17e3ba7a32c50a/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,733 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/a39782166928fc109f1c752a47b59ed1/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,750 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/17caf4e0a9ed1bb532569a413f59abe1/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,753 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/1841e792cdbfa7f1f4536da504c68560/recovered.edits/22.seqid is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,753 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/3783addc127d101a5843032326989852/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,772 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/f092c53f69188d676108ab1dc970629b/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,774 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/a53c806891e4e8573000bb3deb31895e/recovered.edits/25.seqid is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,776 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.CHILD_LINK/78e4a7a00c64a00f1839d32d1a6d61d6/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,874 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/WALs/ambari-agent-02.ambari,16020,1670481872455/ambari-agent-02.ambari%2C16020%2C1670481872455.1670481890182
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,877 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/WALs/ambari-agent-03.ambari,16020,1670481872397/ambari-agent-03.ambari%2C16020%2C1670481872397.meta.1670481887307.meta
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,898 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/WALs/ambari-agent-03.ambari,16020,1670481872397/ambari-agent-03.ambari%2C16020%2C1670481872397.1670481889996
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,913 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/WALs/ambari-agent-01.ambari,16020,1670481873184/ambari-agent-01.ambari%2C16020%2C1670481873184.1670481890944
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:15:43,548 INFO  namenode.FSEditLog
> (FSEditLog.java:printStatistics(794)) - Number of transactions: 344
> Total time for transactions(ms): 32 Number of transactions batched in
> Syncs: 4690 Number of syncs: 268 SyncTimes(ms): 423 2022-12-08
> 07:15:43,548 INFO  hdfs.StateChange
> (FSNamesystem.java:enterSafeMode(4721)) - STATE* Safe mode is ON. It
> was turned on manually. Use "hdfs dfsadmin -safemode leave" to turn
> safe mode off. 2022-12-08 07:16:03,457 INFO  namenode.FSImage
> (FSImage.java:saveNamespace(1146)) - Save namespace ... 2022-12-08
> 07:16:03,458 INFO  namenode.FSEditLog
> (FSEditLog.java:endCurrentLogSegment(1426)) - Ending log segment 4614,
> 4957 2022-12-08 07:16:03,459 INFO  namenode.FSEditLog
> (FSEditLog.java:printStatistics(794)) - Number of transactions: 345
> Total time for transactions(ms): 32 Number of transactions batched in
> Syncs: 4690 Number of syncs: 269 SyncTimes(ms): 425 2022-12-08
> 07:16:03,462 INFO  namenode.FileJournalManager
> (FileJournalManager.java:finalizeLogSegment(145)) - Finalizing edits
> file
> /hadoop/hdfs/namenode/current/edits_inprogress_0000000000000004614 ->
> /hadoop/hdfs/namenode/current/edits_0000000000000004614-0000000000000004958
> 2022-12-08 07:16:03,489 INFO  namenode.FSImageFormatProtobuf
> (FSImageFormatProtobuf.java:save(511)) - Saving image file
> /hadoop/hdfs/namenode/current/fsimage.ckpt_0000000000000004958 using
> no compression 2022-12-08 07:16:03,566 INFO
> namenode.FSImageFormatProtobuf (FSImageFormatProtobuf.java:save(515))
> - Image file /hadoop/hdfs/namenode/current/fsimage.ckpt_0000000000000004958 of size
> 43959 bytes saved in 0 seconds . 2022-12-08 07:16:03,572 INFO
> namenode.NNStorageRetentionManager
> (NNStorageRetentionManager.java:getImageTxIdToRetain(203)) - Going to
> retain 2 images with txid >= 1160 2022-12-08 07:16:03,572 INFO
> namenode.NNStorageRetentionManager
> (NNStorageRetentionManager.java:purgeImage(226)) - Purging old image
> FSImageFile(file=/hadoop/hdfs/namenode/current/fsimage_0000000000000000000,
> cpktTxId=0000000000000000000) 2022-12-08 07:16:03,582 INFO
> namenode.FSEditLog (FSEditLog.java:startLogSegment(1381)) - Starting
> log segment at 4959 2022-12-08 07:16:03,593 INFO
> namenode.FSNamesystem (FSNamesystem.java:saveNamespace(4547)) - New
> namespace image has been created 2022-12-08 07:16:53,274 ERROR
> namenode.NameNode (LogAdapter.java:error(75)) - RECEIVED SIGNAL 15:
> SIGTERM 2022-12-08 07:16:53,278 INFO  namenode.FSImage
> (FSImage.java:lambda$run$0(1053)) - FSImageSaver clean checkpoint:
> txid=4958 when meet shutdown. 2022-12-08 07:16:53,278 INFO
> namenode.NameNode (LogAdapter.java:info(51)) - SHUTDOWN_MSG:
> /************************************************************
> SHUTDOWN_MSG: Shutting down NameNode at ambari-server/172.20.0.2
> ************************************************************/
</code>```

While executing sudo su hdfs -l -c 'hdfs namenode -initializeSharedEdits' command below log is printing

Command Log

Body:
I Cloned the Bigtop code from Github, built RPMS, and installed the Hadoop cluster using Ambari. The Hadoop cluster had 3 nodes. When the name node HA is enabled from Ambari, the services do not start in step 7( Start Components  ), so forward steps cannot be performed. Ambari agent throws some errors when it comes to step 7.

> Ambari-2.7.5
> Hadoop-3.3.4
> Zookeeper-3.5.9
> Linux server: Centos-7

In Ambari agent i am getting the following the error in the log.

> INFO 2022-12-05 13:58:37,440 __init__.py:82 - Event from server at /user/ (correlation_id=227): {u'status': u'OK'}
> ERROR 2022-12-05 13:58:37,704 alert_ha_namenode_health.py:185 - [Alert] NameNode High Availability Health on instance-5 fails:
> Traceback (most recent call last):
> File "/var/lib/ambari-agent/cache/common-services/HDFS/2.1.0.2.0/package/alerts/alert_ha_namenode_health.py", line 175, in execute
> state_response = get_jmx(jmx_uri, connection_timeout)
> File "/var/lib/ambari-agent/cache/common-services/HDFS/2.1.0.2.0/package/alerts/alert_ha_namenode_health.py", line 206, in get_jmx
> response = urllib2.urlopen(query, timeout=connection_timeout)
> File "/usr/lib64/python2.7/urllib2.py", line 154, in urlopen
> return opener.open(url, data, timeout)
> File "/usr/lib64/python2.7/urllib2.py", line 431, in open
> response = self._open(req, data)
> File "/usr/lib64/python2.7/urllib2.py", line 449, in _open
>     '_open', req)
> File "/usr/lib64/python2.7/urllib2.py", line 409, in _call_chain
> result = func(*args)
> File "/usr/lib64/python2.7/urllib2.py", line 1244, in http_open
> return self.do_open(httplib.HTTPConnection, req)
> File "/usr/lib64/python2.7/urllib2.py", line 1214, in do_open
> raise URLError(err)
> URLError: <urlopen error [Errno 111] Connection refused>

Ambari UI While trying to Enable HA

Namenode Log

> 2022-12-08 07:12:52,477 INFO  namenode.FSEditLog
> (FSEditLog.java:printStatistics(794)) - Number of transactions: 168
> Total time for transactions(ms): 19 Number of transactions batched in
> Syncs: 4638 Number of syncs: 143 SyncTimes(ms): 268 2022-12-08
> 07:12:52,481 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/38b9c9dc549394c67f819f03f02ef67c/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,481 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/54a35f5c02b78671aa3cb1a555d4f13d/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,486 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/65daedd407be5de5db0a6df509451aac/recovered.edits/25.seqid is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,489 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.STATS/2b8248a14c2e38b71595200ae6cb6e9c/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,489 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/90de5ae3b5daaf334553cb73d3cffe96/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,495 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/8d944f63f2eec5d95fbf16a45eda13d1/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,496 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/hbase/meta/1588230740/recovered.edits/1300.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,526 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/611f59084c88307ee011a520a00cf1eb/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,529 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/5dbe5b39d39be33e7c549caab73352ba/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,530 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/ba0d8e224fd563575687aab2afa1de39/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,534 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/2760ea047005151d035b988ef5a526f5/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,536 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/f8129cf7b0102dabf7ec9683513c1feb/recovered.edits/25.seqid is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,566 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.TASK/8667cc4454dd118504027c07ed8c150f/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,567 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/a023890792b51c1551471baaf3f385f5/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,567 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/67a1e7ae67d76782a2adbaae3b2687a9/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,582 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/b59bdfcad8908003169571d01f135278/recovered.edits/22.seqid is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,583 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/4c62db7bf1c479ede323e53d21d9a41f/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,583 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/3ea53d95ec4227d5f5fc24c5e79a801f/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,583 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/4604f896ccf933960a21a4f81edfa23f/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,584 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/f0030813232204d5165972d0b99e4a82/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,586 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/0533eb20acb1aa3233403c30dcff05a6/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,612 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/303cb7d7b8ce11cbc4df9bc83e122898/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,615 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/7a766993e99daeb64e3d2219ca8c9427/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,616 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/4a3abf63944203c5020a3f2ef5749c44/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,629 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/6be9c041387ca418f6c35f91135a3b7e/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,629 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/210c8496760d4754384b27bf3b45c072/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,655 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/df5d0ccbe8941453697c89984985ecd1/recovered.edits/22.seqid is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,655 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.CATALOG/ee1348d962c03994578d6bc8f0389831/recovered.edits/43.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,655 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/afa9666d2296f1d7c8629bbc7fc84073/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,662 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/52b00f10bbcede600fe5f434b34629e9/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,665 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/a3fa94f77440b13d37602dace771aa7d/recovered.edits/29.seqid is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,678 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/6c02cf70d5286b712c89a5f136167476/recovered.edits/26.seqid is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,679 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/526cacd3866c13e1c229baa123108783/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,683 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.SEQUENCE/9db3f45bdef2439677f1d7cfed837e24/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,705 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/498c428ad17956df4843f78642957840/recovered.edits/23.seqid is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,706 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/hbase/namespace/bb7e9d3268a1cdf39f49426f0014cf37/recovered.edits/33.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,708 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.MUTEX/c7ec76e62616a4da4f8b81230921dd78/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,709 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/6f89e061764c1ec1a64b608e6e18c62c/recovered.edits/22.seqid is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,710 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.FUNCTION/85740d4c80415117ddf7c8321cabd250/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,714 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/a26508adf2909c8bca5c4f02985bb096/recovered.edits/25.seqid is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,725 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/049bc3d9d7d676e72af6e31163db4364/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,725 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/c96562dd2509624dfe49f1586652e083/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,726 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/65b3fbf36173133b8b368e7fa7b37306/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,727 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/58986e109c517c6893f00bd9c749144a/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,730 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/11de2f3f2cc497467a17e3ba7a32c50a/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,733 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/a39782166928fc109f1c752a47b59ed1/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,750 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/17caf4e0a9ed1bb532569a413f59abe1/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,753 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/1841e792cdbfa7f1f4536da504c68560/recovered.edits/22.seqid is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,753 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/3783addc127d101a5843032326989852/recovered.edits/19.seqid
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:12:52,772 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.LOG/f092c53f69188d676108ab1dc970629b/recovered.edits/22.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,774 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/TEST_MERGE_SPLIT/a53c806891e4e8573000bb3deb31895e/recovered.edits/25.seqid is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,776 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/data/default/SYSTEM.CHILD_LINK/78e4a7a00c64a00f1839d32d1a6d61d6/recovered.edits/25.seqid
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,874 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/WALs/ambari-agent-02.ambari,16020,1670481872455/ambari-agent-02.ambari%2C16020%2C1670481872455.1670481890182
> is closed by DFSClient_NONMAPREDUCE_1334295705_1 2022-12-08
> 07:12:52,877 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/WALs/ambari-agent-03.ambari,16020,1670481872397/ambari-agent-03.ambari%2C16020%2C1670481872397.meta.1670481887307.meta
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,898 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/WALs/ambari-agent-03.ambari,16020,1670481872397/ambari-agent-03.ambari%2C16020%2C1670481872397.1670481889996
> is closed by DFSClient_NONMAPREDUCE_-62228341_1 2022-12-08
> 07:12:52,913 INFO  hdfs.StateChange
> (FSNamesystem.java:completeFile(2979)) - DIR* completeFile:
> /apps/hbase/data/WALs/ambari-agent-01.ambari,16020,1670481873184/ambari-agent-01.ambari%2C16020%2C1670481873184.1670481890944
> is closed by DFSClient_NONMAPREDUCE_1463686342_1 2022-12-08
> 07:15:43,548 INFO  namenode.FSEditLog
> (FSEditLog.java:printStatistics(794)) - Number of transactions: 344
> Total time for transactions(ms): 32 Number of transactions batched in
> Syncs: 4690 Number of syncs: 268 SyncTimes(ms): 423 2022-12-08
> 07:15:43,548 INFO  hdfs.StateChange
> (FSNamesystem.java:enterSafeMode(4721)) - STATE* Safe mode is ON. It
> was turned on manually. Use "hdfs dfsadmin -safemode leave" to turn
> safe mode off. 2022-12-08 07:16:03,457 INFO  namenode.FSImage
> (FSImage.java:saveNamespace(1146)) - Save namespace ... 2022-12-08
> 07:16:03,458 INFO  namenode.FSEditLog
> (FSEditLog.java:endCurrentLogSegment(1426)) - Ending log segment 4614,
> 4957 2022-12-08 07:16:03,459 INFO  namenode.FSEditLog
> (FSEditLog.java:printStatistics(794)) - Number of transactions: 345
> Total time for transactions(ms): 32 Number of transactions batched in
> Syncs: 4690 Number of syncs: 269 SyncTimes(ms): 425 2022-12-08
> 07:16:03,462 INFO  namenode.FileJournalManager
> (FileJournalManager.java:finalizeLogSegment(145)) - Finalizing edits
> file
> /hadoop/hdfs/namenode/current/edits_inprogress_0000000000000004614 ->
> /hadoop/hdfs/namenode/current/edits_0000000000000004614-0000000000000004958
> 2022-12-08 07:16:03,489 INFO  namenode.FSImageFormatProtobuf
> (FSImageFormatProtobuf.java:save(511)) - Saving image file
> /hadoop/hdfs/namenode/current/fsimage.ckpt_0000000000000004958 using
> no compression 2022-12-08 07:16:03,566 INFO
> namenode.FSImageFormatProtobuf (FSImageFormatProtobuf.java:save(515))
> - Image file /hadoop/hdfs/namenode/current/fsimage.ckpt_0000000000000004958 of size
> 43959 bytes saved in 0 seconds . 2022-12-08 07:16:03,572 INFO
> namenode.NNStorageRetentionManager
> (NNStorageRetentionManager.java:getImageTxIdToRetain(203)) - Going to
> retain 2 images with txid >= 1160 2022-12-08 07:16:03,572 INFO
> namenode.NNStorageRetentionManager
> (NNStorageRetentionManager.java:purgeImage(226)) - Purging old image
> FSImageFile(file=/hadoop/hdfs/namenode/current/fsimage_0000000000000000000,
> cpktTxId=0000000000000000000) 2022-12-08 07:16:03,582 INFO
> namenode.FSEditLog (FSEditLog.java:startLogSegment(1381)) - Starting
> log segment at 4959 2022-12-08 07:16:03,593 INFO
> namenode.FSNamesystem (FSNamesystem.java:saveNamespace(4547)) - New
> namespace image has been created 2022-12-08 07:16:53,274 ERROR
> namenode.NameNode (LogAdapter.java:error(75)) - RECEIVED SIGNAL 15:
> SIGTERM 2022-12-08 07:16:53,278 INFO  namenode.FSImage
> (FSImage.java:lambda$run$0(1053)) - FSImageSaver clean checkpoint:
> txid=4958 when meet shutdown. 2022-12-08 07:16:53,278 INFO
> namenode.NameNode (LogAdapter.java:info(51)) - SHUTDOWN_MSG:
> /************************************************************
> SHUTDOWN_MSG: Shutting down NameNode at ambari-server/172.20.0.2
> ************************************************************/

While executing sudo su hdfs -l -c 'hdfs namenode -initializeSharedEdits' command below log is printing

Command Log


来源: stackexchange

问:
Flutter open_file cannot open .apk file directly
I am currently using Open File package to open an apk file from local storage so I can install the said app using a button inside my flutter app and it doesn't work. I tried opening image from local storage it works just fine with this code :

```<code>OpenFile.open(_apkFilePath);
</code>```

But it won't work if I do that exact code on apk file.
Then I tried using picked file just like the example from Open File like the code below :

```<code>Future<void> onClickInstallApk() async {
FilePickerResult? result = await FilePicker.platform.pickFiles();

if (result != null) {
  _apkFilePath = result.files.single.path!;
} else {}
final _result = await OpenFile.open(_apkFilePath);
print(_result.message);

setState(() {
  _openResult = "type=${_result.type}  message=${_result.message}";
});
}
</code>```

I picked the apk file, and it works. The thing is I want apk file to be directly opened without using picked file. I thought that maybe my path was wrong, so I looked at the path gotten from picked file, turns out the file is cached on the app, with the path like this (/data/user/0/appId/cache/file_picker/AppName.apk). I am wondering is it because of the path? Or something else.
Can anyone help me with this? When the apk file failed to open, the log doesn't show anything, as if it was a success opening the file, but on the device, the error was (There was a problem while parsing the package.).

ContentLicense: CC BY-SA 4.0

Body:
I am currently using Open File package to open an apk file from local storage so I can install the said app using a button inside my flutter app and it doesn't work. I tried opening image from local storage it works just fine with this code :

OpenFile.open(_apkFilePath);

But it won't work if I do that exact code on apk file.
Then I tried using picked file just like the example from Open File like the code below :

Future<void> onClickInstallApk() async {
FilePickerResult? result = await FilePicker.platform.pickFiles();

if (result != null) {
  _apkFilePath = result.files.single.path!;
} else {}
final _result = await OpenFile.open(_apkFilePath);
print(_result.message);

setState(() {
  _openResult = "type=${_result.type}  message=${_result.message}";
});
}

I picked the apk file, and it works. The thing is I want apk file to be directly opened without using picked file. I thought that maybe my path was wrong, so I looked at the path gotten from picked file, turns out the file is cached on the app, with the path like this (/data/user/0/appId/cache/file_picker/AppName.apk). I am wondering is it because of the path? Or something else.
Can anyone help me with this? When the apk file failed to open, the log doesn't show anything, as if it was a success opening the file, but on the device, the error was (There was a problem while parsing the package.).


问:
Why do I have memory leakege using threads on Heroku?
I have the following setup on my flask heroku app to avoid timeout exception. Everything is working fine and I can pass the timeout exception.

For some reason after running the Threads multiple times I receive an error from Heroku logs

```<code>Process running mem=628M(122.6%)
heroku[web.1]: Error R14 (Memory quota exceeded)
</code>```

I initially didn't have a join() statment, but this issue appearing even after adding the join() to the threads.

This is my /build route

```<code>   @app.route("/build",methods=["GET", "POST"])
    @login_required
    def build():
        if request.method == "POST":
            global global_dict
            @copy_current_request_context
            def operation(global_dict, session):
                ......
            global t1
            t1 = Thread(target=operation, args=[global_dict, session], name = str(session['user_id'])+'_operation_thread')
            t1.start()

            @copy_current_request_context
            def enter_sql_data(nasdaq_exchange_info, tickers):
               ....
            global t2
            t2 = Thread(target=enter_sql_data, args=[nasdaq_exchange_info, tickers],
            name=str(session['user_id'])+'_sql_thread')
            t2.start()
       return render_template("loading.html")
</code>```

This is where the global flag is being read

```<code>@app.route('/status')
def thread_status():
    userId = session['user_id']
    return jsonify(dict(status=('finished' if (global_dict[int(userId)]['finished'] == 'True') else 'running')))
</code>```

This is the JS on the HTML page where the flag is checked every 1.5 seconds:

```<code><script>
  $(document).ready(function() {
    var refresh_id = setInterval(function() {
        $.get(
          "{{ url_for('thread_status') }}",
          function(data) {
            console.log(data);
            if (data.status == 'finished') {
              window.location.replace("{{ url_for('result') }}");
              clearInterval(refresh_id);
            }
          }
        )}
      , 1500);
  });
</script>
</code>```

This is the result page I am showing at the end of the process

```<code>@app.route('/result')
def result():
    try:
        t1.join()
        t2.join()
        userId=session['user_id']
        return render_template("built.html", num_small=global_dict[int(userId)]['num_small'], plot_json_weights_min_vol_long=global_dict[int(userId)]['plot_json_weights_min_vol_long'], av_min_vol_long=global_dict[int(userId)]['av_min_vol_long'], leftover_min_vol_long=global_dict[int(userId)]['leftover_min_vol_long'], alloc_min_vol_long = global_dict[int(userId)]['alloc_min_vol_long'], plot_json_dist_min_vol_long=global_dict[int(userId)]['plot_json_dist_min_vol_long'], av = global_dict[int(userId)]['av'], leftover_min_vol_long_short=global_dict[int(userId)]['leftover_min_vol_long_short'], alloc_min_vol_long_short=global_dict[int(userId)]['alloc_min_vol_long_short'], ret=global_dict[int(userId)]['ret'],gamma=global_dict[int(userId)]['gamma'],volatility=global_dict[int(userId)]['volatility'], perf_L2=global_dict[int(userId)]['perf_L2'], perf_semi_v=global_dict[int(userId)]['perf_semi_v'], alloc_L2=global_dict[int(userId)]['alloc_L2'], alloc_semi_v=global_dict[int(userId)]['alloc_semi_v'], plot_json_graph=global_dict[int(userId)]['plot_json_graph'], plot_json_exp_cov=global_dict[int(userId)]['plot_json_exp_cov'], plot_json_Ledoit_Wolf=global_dict[int(userId)]['plot_json_Ledoit_Wolf'], plot_json_weight_min_vol_long_short=global_dict[int(userId)]['plot_json_weight_min_vol_long_short'], plot_json_L2_weights=global_dict[int(userId)]['plot_json_L2_weights'], plot_json_L2_port = global_dict[int(userId)]['plot_json_L2_port'], plot_json_semi_v = global_dict[int(userId)]['plot_json_semi_v'], leftover_L2=global_dict[int(userId)]['leftover_L2'], leftover_semi_v=global_dict[int(userId)]['leftover_semi_v'],listofna=(', '.join(global_dict[int(userId)]['listofna'])), min_cvar_rtn = global_dict[int(userId)]['target_CVaR_exp_rtn'], min_cvar_risk = global_dict[int(userId)]['target_CVaR_cond_val_risk'], var = global_dict[int(userId)]['var'], cvar = global_dict[int(userId)]['cvar'], plot_json_cvar=global_dict[int(userId)]['plot_json_cvar'], cvar_value=global_dict[int(userId)]['cvar_value'], alloc_cvar = global_dict[int(userId)]['alloc_cvar'], leftover_cvar = global_dict[int(userId)]['leftover_cvar'])
    except:
        try:
            t1.join()
            t2.join()
            return_error = str(global_dict[int(userId)]['error'])
            flash(return_error)
            return redirect("/build")
        except:
            t1.join()
            t2.join()
            return redirect("/build")
</code>```

Any idea how to avoid the memory leakage?

Body:
I have the following setup on my flask heroku app to avoid timeout exception. Everything is working fine and I can pass the timeout exception.

For some reason after running the Threads multiple times I receive an error from Heroku logs

Process running mem=628M(122.6%)
heroku[web.1]: Error R14 (Memory quota exceeded)

I initially didn't have a join() statment, but this issue appearing even after adding the join() to the threads.

This is my /build route

   @app.route("/build",methods=["GET", "POST"])
    @login_required
    def build():
        if request.method == "POST":
            global global_dict
            @copy_current_request_context
            def operation(global_dict, session):
                ......
            global t1
            t1 = Thread(target=operation, args=[global_dict, session], name = str(session['user_id'])+'_operation_thread')
            t1.start()

            @copy_current_request_context
            def enter_sql_data(nasdaq_exchange_info, tickers):
               ....
            global t2
            t2 = Thread(target=enter_sql_data, args=[nasdaq_exchange_info, tickers],
            name=str(session['user_id'])+'_sql_thread')
            t2.start()
       return render_template("loading.html")

This is where the global flag is being read

@app.route('/status')
def thread_status():
    userId = session['user_id']
    return jsonify(dict(status=('finished' if (global_dict[int(userId)]['finished'] == 'True') else 'running')))

This is the JS on the HTML page where the flag is checked every 1.5 seconds:

This is the result page I am showing at the end of the process

@app.route('/result')
def result():
    try:
        t1.join()
        t2.join()
        userId=session['user_id']
        return render_template("built.html", num_small=global_dict[int(userId)]['num_small'], plot_json_weights_min_vol_long=global_dict[int(userId)]['plot_json_weights_min_vol_long'], av_min_vol_long=global_dict[int(userId)]['av_min_vol_long'], leftover_min_vol_long=global_dict[int(userId)]['leftover_min_vol_long'], alloc_min_vol_long = global_dict[int(userId)]['alloc_min_vol_long'], plot_json_dist_min_vol_long=global_dict[int(userId)]['plot_json_dist_min_vol_long'], av = global_dict[int(userId)]['av'], leftover_min_vol_long_short=global_dict[int(userId)]['leftover_min_vol_long_short'], alloc_min_vol_long_short=global_dict[int(userId)]['alloc_min_vol_long_short'], ret=global_dict[int(userId)]['ret'],gamma=global_dict[int(userId)]['gamma'],volatility=global_dict[int(userId)]['volatility'], perf_L2=global_dict[int(userId)]['perf_L2'], perf_semi_v=global_dict[int(userId)]['perf_semi_v'], alloc_L2=global_dict[int(userId)]['alloc_L2'], alloc_semi_v=global_dict[int(userId)]['alloc_semi_v'], plot_json_graph=global_dict[int(userId)]['plot_json_graph'], plot_json_exp_cov=global_dict[int(userId)]['plot_json_exp_cov'], plot_json_Ledoit_Wolf=global_dict[int(userId)]['plot_json_Ledoit_Wolf'], plot_json_weight_min_vol_long_short=global_dict[int(userId)]['plot_json_weight_min_vol_long_short'], plot_json_L2_weights=global_dict[int(userId)]['plot_json_L2_weights'], plot_json_L2_port = global_dict[int(userId)]['plot_json_L2_port'], plot_json_semi_v = global_dict[int(userId)]['plot_json_semi_v'], leftover_L2=global_dict[int(userId)]['leftover_L2'], leftover_semi_v=global_dict[int(userId)]['leftover_semi_v'],listofna=(', '.join(global_dict[int(userId)]['listofna'])), min_cvar_rtn = global_dict[int(userId)]['target_CVaR_exp_rtn'], min_cvar_risk = global_dict[int(userId)]['target_CVaR_cond_val_risk'], var = global_dict[int(userId)]['var'], cvar = global_dict[int(userId)]['cvar'], plot_json_cvar=global_dict[int(userId)]['plot_json_cvar'], cvar_value=global_dict[int(userId)]['cvar_value'], alloc_cvar = global_dict[int(userId)]['alloc_cvar'], leftover_cvar = global_dict[int(userId)]['leftover_cvar'])
    except:
        try:
            t1.join()
            t2.join()
            return_error = str(global_dict[int(userId)]['error'])
            flash(return_error)
            return redirect("/build")
        except:
            t1.join()
            t2.join()
            return redirect("/build")

Any idea how to avoid the memory leakage?


问:
Make complex footer always stay at the bottom of the page in printing and does not repeat on each printing page
Hi I'm making a printing template with dynamic data. My layout will have a repeated header on each printing page and a footer that only appears on last page and always stay at the bottom of the page. I have read and tried many solutions in this article but none of them can make my footer stay at bottom of the page.

Here is my code:

.wrapper {
    width: 210mm;
    min-height: 100vh;
    margin: auto;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.border-container {
    border: solid 1px #000;
    border-radius: 5px;
    padding: 0 0 15px 0;
}

h1 {
    text-align: center;
    padding: 10px;
}

.table-container {
    width: 100%;
}

.table-container-row {
    display: flex;
    width: 100%;
}

.table-container-item {
    padding: 10px;
    border-left: solid 1px #000;
    border-bottom: solid 1px #000;
}

.table-container-item:first-child {
    border-left: none;
    width: 10%;
}

.table-container-item:nth-child(2) {
    width: 30%;
}

.table-container-item:nth-child(3) {
    width: 40%;
}

.table-container-item:last-child {
    border-right: none;
    width: 20%;
}

.flex {
    display: flex;
}```
<pre class="snippet-code-html lang-html prettyprint-override"><code><!DOCTYPE html>
<html lang="vi">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8;" />
    <link rel="stylesheet" type="text/css" href="test.css" />
    <title>Test</title>
</head>

<body>
    <!-- Wrapper -->
    <div class="wrapper">
        <div>
            <table class="page-table">
                <thead>
                    <tr>
                        <td>
                            <h1>Lorem ipsum dolor sit amet</h1>
                        </td>
                    </tr>
                </thead>
                <tbody>
                    <tr>
                        <td>
                            <div class="border-container">
                                <div class="table-container">
                                    <div class="table-container-row">
                                        <div class="table-container-item">
                                            <strong>Id</strong>
                                        </div>
                                        <div class="table-container-item">
                                            <strong>Name</strong>
                                        </div>
                                        <div class="table-container-item">
                                            <strong>Description</strong>
                                        </div>
                                        <div class="table-container-item">
                                            <strong>Created Date</strong>
                                        </div>
                                    </div>
                                    <div class="table-container-row">
                                        <div class="table-container-item">
                                            <strong>1</strong>
                                        </div>
                                        <div class="table-container-item">
                                            <strong>Test 1</strong>
                                        </div>
                                        <div class="table-container-item"> Lorem ipsum dolor sit amet, consectetur
                                            adipiscing elit. Sed ultrices volutpat hendrerit. Suspendisse venenatis
                                            tempus metus convallis malesuada. Vestibulum consectetur cursus cursus. Sed
                                            fringilla finibus ipsum. Pellentesque quis eros tortor. Interdum et
                                            malesuada fames ac ante ipsum primis in faucibus. Morbi vel lacus vel mi
                                            ullamcorper varius vel elementum tellus. Suspendisse placerat, risus nec
                                            ultricies pulvinar, felis purus venenatis sem, vitae blandit tortor dui nec
                                            metus. Proin quis turpis sodales, aliquam erat vel, imperdiet nunc. Proin
                                            condimentum tellus est, eget eleifend turpis tristique et. Proin maximus
                                            congue tellus. Nulla ut cursus erat. Pellentesque vel rutrum ipsum, sit amet
                                            mollis arcu. Morbi pulvinar nibh eu risus sollicitudin accumsan. Vivamus
                                            quis purus sit amet felis euismod tristique ac eu magna. <br />
                                            <br /> Etiam dignissim urna eu nulla pellentesque egestas. Ut id placerat
                                            dui. Etiam nibh felis, aliquet id semper sed, sollicitudin eu nisi. In hac
                                            habitasse platea dictumst. Duis lobortis dui elit, ut laoreet dolor
                                            venenatis et. Phasellus dictum magna vel justo tincidunt, eu eleifend massa
                                            pellentesque. Fusce eu nulla dignissim, efficitur justo non, mattis dui.
                                            Fusce id rutrum purus. Nam ornare dictum mauris dictum blandit. Quisque in
                                            quam vitae tellus tincidunt dictum. Quisque commodo ultrices ante ut
                                            euismod. Suspendisse ut purus molestie, pellentesque augue a, accumsan dui.
                                            Fusce imperdiet ante quis metus posuere, in elementum sem luctus.
                                        </div>
                                        <div class="table-container-item"> 11/20/2023 </div>
                                    </div>
                                    <div class="table-container-row">
                                        <div class="table-container-item">
                                            <strong>2</strong>
                                        </div>
                                        <div class="table-container-item">
                                            <strong>Test 2</strong>
                                        </div>
                                        <div class="table-container-item"> Morbi vel tincidunt tellus. Nam vel mollis
                                            odio. Quisque consequat blandit libero, sit amet scelerisque neque convallis
                                            vel. Nullam eleifend quam nunc, quis vestibulum augue accumsan ut.
                                            Vestibulum posuere ligula vel pharetra congue. Vestibulum odio urna,
                                            faucibus quis convallis id, dictum ut ex. Sed eleifend leo id urna
                                            convallis, sed pharetra dolor tincidunt. Cras gravida fringilla tellus id
                                            dignissim. Etiam in quam vel odio finibus accumsan. Nullam rhoncus erat
                                            massa, ac lobortis sem lacinia vel. Proin dignissim hendrerit eros sit amet
                                            tincidunt. Aliquam lacinia in enim at rutrum. Proin eu aliquam tellus.
                                            Nullam mattis bibendum est, vitae vestibulum sem finibus et. Ut elementum
                                            justo eget odio tincidunt, ac fermentum est pellentesque. <br />
                                            <br /> Suspendisse at ante ligula. Sed tempus orci vel semper fringilla.
                                            Aenean pellentesque sapien diam, eget fermentum leo laoreet ut. Donec
                                            interdum finibus enim, in rhoncus felis tempor at. Morbi porttitor sem ante,
                                            eget lacinia diam feugiat nec. Quisque vel justo purus. Aliquam vel faucibus
                                            tortor. Aenean sodales, erat nec sodales dapibus, ligula lorem sagittis
                                            risus, id tincidunt arcu nibh at felis. Curabitur vel mauris non velit
                                            feugiat blandit. Mauris posuere, metus eu scelerisque pretium, massa elit
                                            tristique turpis, ut fringilla sapien velit nec sapien. Mauris gravida
                                            fermentum molestie. Curabitur consectetur ipsum sed elit dictum blandit.
                                            Maecenas eget ante a odio faucibus bibendum nec eu justo.
                                        </div>
                                        <div class="table-container-item"> 11/20/2023 </div>
                                    </div>
                                </div>
                                <ul>
                                    <li>Lorem ipsum dolor sit amet,</li>
                                    <li>Lorem ipsum dolor sit amet,</li>
                                    <li>Lorem ipsum dolor sit amet,</li>
                                </ul>
                            </div>
                        </td>
                    </tr>
                </tbody>
            </table>
        </div>
        <div class="footer">
            <div class="flex">
                <div style="width: 50%">
                    <ul>
                        <li>Aenean eget ultricies nisi.</li>
                        <li>Fusce molestie finibus dapibus.</li>
                        <li>Vivamus mi enim, posuere sed mollis at, dapibus nec enim.</li>
                    </ul>
                </div>
                <div style="width: 50%">
                    <ul>
                        <li>Aenean eget ultricies nisi.</li>
                        <li>Fusce molestie finibus dapibus.</li>
                        <li>Vivamus mi enim, posuere sed mollis at, dapibus nec enim.</li>
                        <li>Morbi vel tincidunt tellus.</li>
                    </ul>
                </div>
            </div>
        </div>
    </div>
</body>

</html></code>```

Body:
Hi I'm making a printing template with dynamic data. My layout will have a repeated header on each printing page and a footer that only appears on last page and always stay at the bottom of the page. I have read and tried many solutions in this article but none of them can make my footer stay at bottom of the page.

Here is my code:

.wrapper {
    width: 210mm;
    min-height: 100vh;
    margin: auto;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.border-container {
    border: solid 1px #000;
    border-radius: 5px;
    padding: 0 0 15px 0;
}

h1 {
    text-align: center;
    padding: 10px;
}

.table-container {
    width: 100%;
}

.table-container-row {
    display: flex;
    width: 100%;
}

.table-container-item {
    padding: 10px;
    border-left: solid 1px #000;
    border-bottom: solid 1px #000;
}

.table-container-item:first-child {
    border-left: none;
    width: 10%;
}

.table-container-item:nth-child(2) {
    width: 30%;
}

.table-container-item:nth-child(3) {
    width: 40%;
}

.table-container-item:last-child {
    border-right: none;
    width: 20%;
}

.flex {
    display: flex;
}

<!DOCTYPE html>

    <meta charset="UTF-8">
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8;" />
    <link rel="stylesheet" type="text/css" href="test.css" />
    <title>Test</title>

Lorem ipsum dolor sit amet

                                            Id

                                            Name

                                            Description

                                            Created Date

                                            1

                                            Test 1

 Lorem ipsum dolor sit amet, consectetur
                                            adipiscing elit. Sed ultrices volutpat hendrerit. Suspendisse venenatis
                                            tempus metus convallis malesuada. Vestibulum consectetur cursus cursus. Sed
                                            fringilla finibus ipsum. Pellentesque quis eros tortor. Interdum et
                                            malesuada fames ac ante ipsum primis in faucibus. Morbi vel lacus vel mi
                                            ullamcorper varius vel elementum tellus. Suspendisse placerat, risus nec
                                            ultricies pulvinar, felis purus venenatis sem, vitae blandit tortor dui nec
                                            metus. Proin quis turpis sodales, aliquam erat vel, imperdiet nunc. Proin
                                            condimentum tellus est, eget eleifend turpis tristique et. Proin maximus
                                            congue tellus. Nulla ut cursus erat. Pellentesque vel rutrum ipsum, sit amet
                                            mollis arcu. Morbi pulvinar nibh eu risus sollicitudin accumsan. Vivamus
                                            quis purus sit amet felis euismod tristique ac eu magna.

 Etiam dignissim urna eu nulla pellentesque egestas. Ut id placerat
                                            dui. Etiam nibh felis, aliquet id semper sed, sollicitudin eu nisi. In hac
                                            habitasse platea dictumst. Duis lobortis dui elit, ut laoreet dolor
                                            venenatis et. Phasellus dictum magna vel justo tincidunt, eu eleifend massa
                                            pellentesque. Fusce eu nulla dignissim, efficitur justo non, mattis dui.
                                            Fusce id rutrum purus. Nam ornare dictum mauris dictum blandit. Quisque in
                                            quam vitae tellus tincidunt dictum. Quisque commodo ultrices ante ut
                                            euismod. Suspendisse ut purus molestie, pellentesque augue a, accumsan dui.
                                            Fusce imperdiet ante quis metus posuere, in elementum sem luctus.

 11/20/2023

                                            2

                                            Test 2

 Morbi vel tincidunt tellus. Nam vel mollis
                                            odio. Quisque consequat blandit libero, sit amet scelerisque neque convallis
                                            vel. Nullam eleifend quam nunc, quis vestibulum augue accumsan ut.
                                            Vestibulum posuere ligula vel pharetra congue. Vestibulum odio urna,
                                            faucibus quis convallis id, dictum ut ex. Sed eleifend leo id urna
                                            convallis, sed pharetra dolor tincidunt. Cras gravida fringilla tellus id
                                            dignissim. Etiam in quam vel odio finibus accumsan. Nullam rhoncus erat
                                            massa, ac lobortis sem lacinia vel. Proin dignissim hendrerit eros sit amet
                                            tincidunt. Aliquam lacinia in enim at rutrum. Proin eu aliquam tellus.
                                            Nullam mattis bibendum est, vitae vestibulum sem finibus et. Ut elementum
                                            justo eget odio tincidunt, ac fermentum est pellentesque.

 Suspendisse at ante ligula. Sed tempus orci vel semper fringilla.
                                            Aenean pellentesque sapien diam, eget fermentum leo laoreet ut. Donec
                                            interdum finibus enim, in rhoncus felis tempor at. Morbi porttitor sem ante,
                                            eget lacinia diam feugiat nec. Quisque vel justo purus. Aliquam vel faucibus
                                            tortor. Aenean sodales, erat nec sodales dapibus, ligula lorem sagittis
                                            risus, id tincidunt arcu nibh at felis. Curabitur vel mauris non velit
                                            feugiat blandit. Mauris posuere, metus eu scelerisque pretium, massa elit
                                            tristique turpis, ut fringilla sapien velit nec sapien. Mauris gravida
                                            fermentum molestie. Curabitur consectetur ipsum sed elit dictum blandit.
                                            Maecenas eget ante a odio faucibus bibendum nec eu justo.

 11/20/2023

Lorem ipsum dolor sit amet,

Lorem ipsum dolor sit amet,

Lorem ipsum dolor sit amet,

Aenean eget ultricies nisi.

Fusce molestie finibus dapibus.

Vivamus mi enim, posuere sed mollis at, dapibus nec enim.

Aenean eget ultricies nisi.

Fusce molestie finibus dapibus.

Vivamus mi enim, posuere sed mollis at, dapibus nec enim.

Morbi vel tincidunt tellus.


问:
Hibernate Error - while inserting from select
Basically, for some reason, I need to conditionally insert data from one table to another, for later use in postgres.

I am doing this within a spring boot app, with legacy hibernate SQLQuery implementation.

For purpose, created a destination table below with exact column type in source table

```<code>CREATE TABLE billing_query (
    id float8 NOT NULL,
    created_ts timestamp(6) NOT NULL,
    trip_date timestamp(0) NULL,
    CONSTRAINT billing_query_pk PRIMARY KEY (id, created_ts)
   );
</code>```

Below is hbm mapping:

```<code><hibernate-mapping package="xyz.model">

    <class name="BillingQuery" table="BILLING_QUERY">
        <id column="ID" name="id"/>
        <property name="createdTs" column="CREATED_TS" type="java.util.Date" />
        <property name="tripDate" column="TRIP_DATE" type="timestamp" />
    </class>

</hibernate-mapping>
</code>```

And Model:

```<code>public class BillingQuery implements Serializable {

    private Long id;

    private Date createdTs;

    private Date startOfTripDate;
}
</code>```

But whenever I am trying to execute query (insert from select), the app is throwing below error

Error: column "created_ts" is of type timestamp without time zone but
expression is of type character varying

Below is the printed sql query (with java.util.date being passed as paramter)

```<code>insert into billing_query
select t.ID as ID, t.CREATED_TS as CREATED_TS, t.TRIP_DATE as TRIP_DATE
from trip t
where t.TRIP_DATE = ?
  and t.FLAG='Y'
</code>```

Mapping in java:

```<code>query.setTimestamp(i++, eq.getSot());
</code>```

Appreciate any assistance in same regards. Tried casting using ::timestamp and to_timestamp in select but still same error.

Body:
Basically, for some reason, I need to conditionally insert data from one table to another, for later use in postgres.

I am doing this within a spring boot app, with legacy hibernate SQLQuery implementation.

For purpose, created a destination table below with exact column type in source table

CREATE TABLE billing_query (
    id float8 NOT NULL,
    created_ts timestamp(6) NOT NULL,
    trip_date timestamp(0) NULL,
    CONSTRAINT billing_query_pk PRIMARY KEY (id, created_ts)
   );

Below is hbm mapping:

<hibernate-mapping package="xyz.model">

    <class name="BillingQuery" table="BILLING_QUERY">
        <id column="ID" name="id"/>
        <property name="createdTs" column="CREATED_TS" type="java.util.Date" />
        <property name="tripDate" column="TRIP_DATE" type="timestamp" />
    </class>

</hibernate-mapping>

And Model:

public class BillingQuery implements Serializable {

    private Long id;

    private Date createdTs;

    private Date startOfTripDate;
}

But whenever I am trying to execute query (insert from select), the app is throwing below error

Error: column "created_ts" is of type timestamp without time zone but
expression is of type character varying

Below is the printed sql query (with java.util.date being passed as paramter)

insert into billing_query
select t.ID as ID, t.CREATED_TS as CREATED_TS, t.TRIP_DATE as TRIP_DATE
from trip t
where t.TRIP_DATE = ?
  and t.FLAG='Y'

Mapping in java:

query.setTimestamp(i++, eq.getSot());

Appreciate any assistance in same regards. Tried casting using ::timestamp and to_timestamp in select but still same error.


问:
Windows 10 PowerShell - Get-AppxPackage finds package, Remove-AppxPackage cannot remove it
How can I remove a seemingly spurious package in Windows 10? Remove-AppxPackage does not seem to work. The package must be a left-over from a previous install of the software that we develop. It looks like this in PowerShell:

PS C:\Windows\system32> Get-AppxPackage -all | Select-String SEARCH_STRING

FULL_PACKAGE_NAME

PS C:\Windows\system32> Remove-AppxPackage

cmdlet Remove-AppxPackage at command pipeline position 1
Supply values for the following parameters:
Package: FULL_PACKAGE_NAME

PS C:\Windows\system32> Get-AppxPackage -all | Select-String FULL_PACKAGE_NAME

FULL_PACKAGE_NAME

What I tried: I tried removing a package with Remove-AppxPackage and the package was not removed. I tried both the full package name and the abridged package name as returned by Get-AppxPackage.

Prior to this, I did a regular uninstall of the app the package belongs to.


问:
This field is required DRF Nested Serializers
I'm getting This field is required error while creating a nested serializer. I have ReviewRatings and ReviewImages models in which ReviewImages is FK to ReviewRatings so that an user can upload single or multiple images along with reviews. And the problem arises when i don't add required=True in serializer. If it's False then there is no problem at all.

#Models.py

```<code>
class ReviewRatings(models.Model):
    user = models.ForeignKey(Account, on_delete=models.CASCADE)
    product = models.ForeignKey(Products, on_delete=models.CASCADE)
    rating = models.FloatField(validators=[MinValueValidator(0), MaxValueValidator(5)])
    created_at = models.DateField(auto_now_add=True)
    review = models.CharField(max_length=500, null=True)
    updated_at = models.DateField(auto_now=True)

    class Meta:
        verbose_name_plural = "Reviews & Ratings"

    def __str__(self):
        return self.product.product_name

class ReviewImages(models.Model):
    review = models.ForeignKey(
        ReviewRatings,
        on_delete=models.CASCADE,
        related_name="review_images",
        null=True,
        blank=True,
    )
    images = models.ImageField(upload_to="reviews/review-images", null=True, blank=True)

    def __str__(self):
        return str(self.images)

</code>```

#Serializers.py

```<code>
class ReviewImagesSerializer(ModelSerializer):
    class Meta:
        model = ReviewImages
        fields = ["images"]

class ReviewSerializer(ModelSerializer):
    user = SerializerMethodField()
    review_images = ReviewImagesSerializer(many=True, required=False)

    class Meta:
        model = ReviewRatings
        fields = [
            "user",
            "rating",
            "review",
            "created_at",
            "updated_at",
            "review_images",
        ]

    def get_user(self, obj):
        return f"{obj.user.first_name} {obj.user.last_name}"

    def validate(self, obj):
        review_images = self.context["images"]
        max_size = [5 * 1024 * 1024]
        rev_img_size = [i.size for i in review_images]
        if rev_img_size > max_size:
            raise ValidationError({"error": "Size cannot exceed 5 MB"})
        elif len(review_images) > 3:
            raise ValidationError({"error": "you cant upload more than 3 photos"})
        return obj

    def create(self, validated_data):
        review_images = self.context["images"]
        reviews = ReviewRatings.objects.create(**validated_data)
        for image in review_images:
            ReviewImages.objects.create(review=reviews, images=image)
        return reviews
</code>```

#Views.py

```<code>class SubmitReview(APIView):
    permission_classes = [IsAuthenticated]

    def post(self, request, product_slug):
        data = request.data
        review_images = request.FILES.getlist("review_images")
        if data["rating"] == "" and data["review"] == "":
            raise ValidationError({"detail": "Fields cannot be blank"})
        product = Products.objects.get(slug=product_slug)
        if ReviewRatings.objects.filter(
            user=request.user, product__slug=product_slug
        ).exists():
            return Response({"detail": "You have already submitted the review "})
        serializer = ReviewSerializer(
            data=request.data, context={"request": request,'images':review_images}
        )
        if serializer.is_valid():
            serializer.save(user=request.user, product=product)
            return Response(serializer.data, status=status.HTTP_201_CREATED)
        else:
            return Response(serializer.errors)

</code>```

In this am getting list of images(Multiple image upload) and for that I had to do review_images = request.FILES.getlist("review_images") and pass it in context to ReviewRatingSerializer.

So if I dont have required=False in review_images = ReviewImagesSerializer(many=True, required=False) in ReviewRatingSerializer then the review along with images get created,
otherwise required=True then the response will be

```<code>{
    "review_images": [
        "This field is required."
    ]
}
</code>```

Body:
I'm getting This field is required error while creating a nested serializer. I have ReviewRatings and ReviewImages models in which ReviewImages is FK to ReviewRatings so that an user can upload single or multiple images along with reviews. And the problem arises when i don't add required=True in serializer. If it's False then there is no problem at all.

#Models.py

class ReviewRatings(models.Model):
    user = models.ForeignKey(Account, on_delete=models.CASCADE)
    product = models.ForeignKey(Products, on_delete=models.CASCADE)
    rating = models.FloatField(validators=[MinValueValidator(0), MaxValueValidator(5)])
    created_at = models.DateField(auto_now_add=True)
    review = models.CharField(max_length=500, null=True)
    updated_at = models.DateField(auto_now=True)

    class Meta:
        verbose_name_plural = "Reviews & Ratings"

    def __str__(self):
        return self.product.product_name

class ReviewImages(models.Model):
    review = models.ForeignKey(
        ReviewRatings,
        on_delete=models.CASCADE,
        related_name="review_images",
        null=True,
        blank=True,
    )
    images = models.ImageField(upload_to="reviews/review-images", null=True, blank=True)

    def __str__(self):
        return str(self.images)

#Serializers.py

class ReviewImagesSerializer(ModelSerializer):
    class Meta:
        model = ReviewImages
        fields = ["images"]

class ReviewSerializer(ModelSerializer):
    user = SerializerMethodField()
    review_images = ReviewImagesSerializer(many=True, required=False)

    class Meta:
        model = ReviewRatings
        fields = [
            "user",
            "rating",
            "review",
            "created_at",
            "updated_at",
            "review_images",
        ]

    def get_user(self, obj):
        return f"{obj.user.first_name} {obj.user.last_name}"

    def validate(self, obj):
        review_images = self.context["images"]
        max_size = [5 * 1024 * 1024]
        rev_img_size = [i.size for i in review_images]
        if rev_img_size > max_size:
            raise ValidationError({"error": "Size cannot exceed 5 MB"})
        elif len(review_images) > 3:
            raise ValidationError({"error": "you cant upload more than 3 photos"})
        return obj

    def create(self, validated_data):
        review_images = self.context["images"]
        reviews = ReviewRatings.objects.create(**validated_data)
        for image in review_images:
            ReviewImages.objects.create(review=reviews, images=image)
        return reviews

#Views.py

class SubmitReview(APIView):
    permission_classes = [IsAuthenticated]

    def post(self, request, product_slug):
        data = request.data
        review_images = request.FILES.getlist("review_images")
        if data["rating"] == "" and data["review"] == "":
            raise ValidationError({"detail": "Fields cannot be blank"})
        product = Products.objects.get(slug=product_slug)
        if ReviewRatings.objects.filter(
            user=request.user, product__slug=product_slug
        ).exists():
            return Response({"detail": "You have already submitted the review "})
        serializer = ReviewSerializer(
            data=request.data, context={"request": request,'images':review_images}
        )
        if serializer.is_valid():
            serializer.save(user=request.user, product=product)
            return Response(serializer.data, status=status.HTTP_201_CREATED)
        else:
            return Response(serializer.errors)

In this am getting list of images(Multiple image upload) and for that I had to do review_images = request.FILES.getlist("review_images") and pass it in context to ReviewRatingSerializer.

So if I dont have required=False in review_images = ReviewImagesSerializer(many=True, required=False) in ReviewRatingSerializer then the review along with images get created,
otherwise required=True then the response will be

{
    "review_images": [
        "This field is required."
    ]
}


问:
How to get the name of the XML tag as a whole in C#?
I have the following content in my XML file:

```<code><SOAP:Body>
  <si:myId>
   43h4b-12s22-gj3ls
  </si:myId>
</SOAP:Body>
</code>```

What I want to do is extracting the name of the XML tag as a whole (ex: "<si:myId>").

However, I can not achieve that with C#. The maximum that I can do is to extract the "LocalName", which is "myId" as shown in the example below:

```<code>foreach(var element in xDocument.Descendants())
{
    string name = element.Name.LocalName; // ex: myId
}
</code>```

I would be very happy if you would help me to get the tag with full name (ex: "si:myId").

Body:
I have the following content in my XML file:

<SOAP:Body>
  <si:myId>
   43h4b-12s22-gj3ls
  </si:myId>
</SOAP:Body>

What I want to do is extracting the name of the XML tag as a whole (ex: "<si:myId>").

However, I can not achieve that with C#. The maximum that I can do is to extract the "LocalName", which is "myId" as shown in the example below:

foreach(var element in xDocument.Descendants())
{
    string name = element.Name.LocalName; // ex: myId
}

I would be very happy if you would help me to get the tag with full name (ex: "si:myId").


问:
How to draw a graph with pgfplots in LaTeX
What is the simplest way to draw graph like this in Latex?

I tried but I don't know how to write a code for that.

```<code>\documentclass{report}
\usepackage{tikz}

\begin{document}

\begin{tikzpicture}
\draw[help lines, color=gray!30, dashed] (-4.9,-4.9) grid (4.9,4.9);
\draw[->,ultra thick] (-8,0)--(8,0) node[right]{$x$};
\draw[->,ultra thick] (0,-8)--(0,8) node[above]{$y$};

  % First, define nodes
  \draw (0,0) node[circle, inner sep=2pt, fill=black, label={below:{$A(0,0)$}}] (A) {};
  \draw (5,0) node[circle, inner sep=2pt, fill=black, label={below:{$B(5,0)$}}] (B) {};
  \draw (2,2) node[circle, inner sep=2pt, fill=black, label={below:{$C(2,2)$}}] (C) {};
  \draw (1.5,-2) node[circle, inner sep=2pt, fill=black, label={below:{$D(1.5,-2)$}}] (D) {};

  % Draw curved path
  \draw[black]  (A) -- (B);
  \draw[black]  (A) -- (C);
  \draw[black]  (A) -- (D);
  \draw[black]  (C) -- (B);
  \draw[black]  (D) -- (B);
  \draw[red]  (A) .. controls +(-0.1,1.5) and +(0.5,2).. (C);
  \path[->] (A)  edge [bend left] node {aaaa} (C);

\end{tikzpicture}

\end{document}
</code>```

Body:
What is the simplest way to draw graph like this in Latex?

I tried but I don't know how to write a code for that.

\documentclass{report}
\usepackage{tikz}

\begin{document}

\begin{tikzpicture}
\draw[help lines, color=gray!30, dashed] (-4.9,-4.9) grid (4.9,4.9);
\draw[->,ultra thick] (-8,0)--(8,0) node[right]{$x$};
\draw[->,ultra thick] (0,-8)--(0,8) node[above]{$y$};

  % First, define nodes
  \draw (0,0) node[circle, inner sep=2pt, fill=black, label={below:{$A(0,0)$}}] (A) {};
  \draw (5,0) node[circle, inner sep=2pt, fill=black, label={below:{$B(5,0)$}}] (B) {};
  \draw (2,2) node[circle, inner sep=2pt, fill=black, label={below:{$C(2,2)$}}] (C) {};
  \draw (1.5,-2) node[circle, inner sep=2pt, fill=black, label={below:{$D(1.5,-2)$}}] (D) {};

  % Draw curved path
  \draw[black]  (A) -- (B);
  \draw[black]  (A) -- (C);
  \draw[black]  (A) -- (D);
  \draw[black]  (C) -- (B);
  \draw[black]  (D) -- (B);
  \draw[red]  (A) .. controls +(-0.1,1.5) and +(0.5,2).. (C);
  \path[->] (A)  edge [bend left] node {aaaa} (C);

\end{tikzpicture}

\end{document}


问:
Varchar2 in SQLmodel schema wrong translation
I use an oracle database as a server into my application. My SQLModel schema looks like below:

```<code>class HostOutput(SQLModel):
    name: str = Field(index=True)
    region: Optional[str] = None
    os_type: Optional[int] = None
    os_version: Optional[str] = None
    network: Optional[int] = None
</code>```

Whenever I start my application , sqlalchemy cannot translate the input  of a string into VARCHAR2 type in oracle's database. The problem is that VARCHAR2 type requires the amount of bytes for a particular field(column) in Oracle. And the error I get is:

```<code>sqlalchemy.exc.DatabaseError: (cx_Oracle.DatabaseError) ORA-00906: missing left parenthesis
[SQL:
CREATE TABLE host (
        name VARCHAR2 NOT NULL,
        region VARCHAR2,
        os_type INTEGER,
        os_version VARCHAR2,
        network INTEGER,
        id INTEGER NOT NULL,
        PRIMARY KEY (id)
)

]
(Background on this error at: https://sqlalche.me/e/14/4xp6)
</code>```

which essentially translates to the database complaining about VARCHAR2 not having parenthesis, for example VARCHAR(5) would be the correct data type.

I tried the following:

```<code>from sqlalchemy import String

class HostOutput(SQLModel):
    name: str = Field(index=True)
    region: Optional[String(2)] = None
    os_type: Optional[int] = None
    os_version: Optional[str] = None
    network: Optional[int] = None
</code>```

but then I get this typing error from python:

```<code>TypeError: typing.Optional requires a single type. Got String(length=2).
</code>```

Body:
I use an oracle database as a server into my application. My SQLModel schema looks like below:

class HostOutput(SQLModel):
    name: str = Field(index=True)
    region: Optional[str] = None
    os_type: Optional[int] = None
    os_version: Optional[str] = None
    network: Optional[int] = None

Whenever I start my application , sqlalchemy cannot translate the input  of a string into VARCHAR2 type in oracle's database. The problem is that VARCHAR2 type requires the amount of bytes for a particular field(column) in Oracle. And the error I get is:

sqlalchemy.exc.DatabaseError: (cx_Oracle.DatabaseError) ORA-00906: missing left parenthesis
[SQL:
CREATE TABLE host (
        name VARCHAR2 NOT NULL,
        region VARCHAR2,
        os_type INTEGER,
        os_version VARCHAR2,
        network INTEGER,
        id INTEGER NOT NULL,
        PRIMARY KEY (id)
)

]
(Background on this error at: https://sqlalche.me/e/14/4xp6)

which essentially translates to the database complaining about VARCHAR2 not having parenthesis, for example VARCHAR(5) would be the correct data type.

I tried the following:

from sqlalchemy import String

class HostOutput(SQLModel):
    name: str = Field(index=True)
    region: Optional[String(2)] = None
    os_type: Optional[int] = None
    os_version: Optional[str] = None
    network: Optional[int] = None

but then I get this typing error from python:

TypeError: typing.Optional requires a single type. Got String(length=2).


问:
Difference in Length of ImageBytes while performing PIL IMAGE .getvalue() operation on AWS LAMBDA?
I am trying to perform .getvalue() operation on PIL image on AWS Lambda to extract the bytes of PIL Image but my byte string length is different when i perform this operation on Local Machine and Its different when i Perform it on AWS Lambda, below is code

```<code>if base64_message[0:4] == b'%PDF':

        images = convert_from_bytes(base64_message, dpi=120, poppler_path=poppler_path)

        img_byte_arr = io.BytesIO()
        for img_page in (images):

            img_page.save(img_byte_arr, format = "jpeg")
            break
        img_obj = img_byte_arr.getvalue()

**print(len(img_obj))**

</code>```

Basically I am trying using pdf2image library to get image byte from pdf but length of the bytes are different on Local Machine and its Different on AWS lambda which impacting by futher operation.

for particular Image, length of Imagebyte on AWS Lambda is  122103
and for same image it's 122551 on Local Machine.

Solution - After making some research i figured out that this issue is happening due to Lambda Linux Environment and i developed my entire application on Windows Machine, so different operating system is the issue.

Body:
I am trying to perform .getvalue() operation on PIL image on AWS Lambda to extract the bytes of PIL Image but my byte string length is different when i perform this operation on Local Machine and Its different when i Perform it on AWS Lambda, below is code

if base64_message[0:4] == b'%PDF':

        images = convert_from_bytes(base64_message, dpi=120, poppler_path=poppler_path)

        img_byte_arr = io.BytesIO()
        for img_page in (images):

            img_page.save(img_byte_arr, format = "jpeg")
            break
        img_obj = img_byte_arr.getvalue()

**print(len(img_obj))**

Basically I am trying using pdf2image library to get image byte from pdf but length of the bytes are different on Local Machine and its Different on AWS lambda which impacting by futher operation.

for particular Image, length of Imagebyte on AWS Lambda is  122103
and for same image it's 122551 on Local Machine.

Solution - After making some research i figured out that this issue is happening due to Lambda Linux Environment and i developed my entire application on Windows Machine, so different operating system is the issue.


问:
How to control the audio/video data rate in Gstreamer?
i am trying to stream the audio data across two systems and want to control the data rate if possible.

"gst-launch-1.0 alsasrc ! audio/x-raw, rate=12000, channels=1,format=S16LE, layouy=interleaved ! udpsink host=Destination IP port=8000"

How to control the audio stream data rate in Gstream.

Quick suggestion will be highly appreciated.

Tried to stream the audio using VLC player where i could control the data rate. However there is no control on the packet size in VLC so thought of using Gstream for the streaming. Newbie to gstream and tried the following for the same.

i tried gstream pipeline across the systems for streaming the audio network speed.
My requirement is to stream the data@ 100Kbps.

"gst-launch-1.0 alsasrc ! audio/x-raw, rate=12000, channels=1,format=S16LE, layouy=interleaved ! udpsink host=Destination IP port=8000"

Need Gstream pipeline with data rate control @ 100Kbps (variable)